#include <stdio.h>
#define sqr(x) (x*x)
int main()
{
int x=2;
printf("value of x=%d",sqr(x+1));
}
What is the value of x?
Answer Posted / jugal
Sorry guys,
my bad,
i thought it was
#define sqr(x) ((x)*(x))
the output wud be 5
but still the value of will be 2 only
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What is a void pointer in c?
Is that possible to add pointers to each other?
What are the various types of control structures in programming?
What library is sizeof in c?
What is the best style for code layout in c?
Explain how can I manipulate strings of multibyte characters?
What are the different types of data structures in c?
What is the basic structure of c?
What is wrong with this statement? Myname = 'robin';
What is nested structure?
What is identifiers in c with examples?
What are 'near' and 'far' pointers?
Why c language?
how much salary u want ? why u join in our company? your domain is core sector why u prefer software ?
C program execution always begins with a) #include b) comment (/*-------*/) c) main() d) declaration instructions