For given SQUARE macro definition, what value will be shown on a screen after executing next code:
#define SQUARE(x) ((x)*(x))
int m = 4;
SQUARE(++m);
std::cout << r;
Explanation
During the #define directive execution, text substitution of each symbol "X", that was found in the body of the function, to the current value of the variable "m" is performed. Thus, after such type of replacement current, the ​value of "m" is increased by 1.

Слідкуй за CodeGalaxy

Мобільний додаток Beta

Get it on Google Play
Зворотній Зв’язок
Cosmo
Зареєструйся Зараз
або Підпишись на майбутні тести