Consider the following code:
#define SQ(a) (a*a)
int answer = SQ(2 + 3);
What will be the value of answer after the above code executes?
Answers
Answered by
5
Answer:
The output of the code will be 25
Answered by
0
Answer:
The answer is 25.
Explanation:
i) The given code can be converted to a mathematical function as:
f(a) = a x a
ii) The value of this function at given value of 'a':
f(2+3)= f(5) = 5 x 5 = 25.
iii) Hence, the value of answer after the execution of code will be 25.
#SPJ3
Similar questions
Computer Science,
5 months ago
Chemistry,
5 months ago
Science,
11 months ago
Physics,
11 months ago