0
Can some one explain this?
#include <stdio.h> #define sqr(i) i*i int main() { printf ("%d %d",sqr(3),sqr(3+1)); return 0; }
5 Answers
+ 1
sqr (3) = 3*3 = 9
sqr (3+1) = 3+1*3+1 = 7
+ 3
sqr
sqr (3) = 3*3 = 9
Its calculate like this
sqr (3+1) = 3+1*3+1 is equal to 7
0
its not a function, its a macro.
0
i am a master c++ so do not try to callange meš