# define x=1+4;
main()
{
int x;
printf("%d%d",x/2,x/4);
}
Answer Posted / rama krishna sidhartha
The preprocessor syntax is wrongly written. It should be as
follows :
#define x 1+4
void main()
{
printf("%d%d",x/2,x/4);
}
There is no need of declaring the variable 'x' in
between 'main()' function since it is already declared
in '#define' directive.
The output will be : 3 and 2
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
What are runtime error?
Explain the process of converting a Tree into a Binary Tree.
What do you mean by Recursion Function?
which of the following shows the correct hierarchy of arithmetic operations in C a) (), **, * or/,+ or - b) (),**,*,/,+,- c) (),**,/,*,+,- d) (),/ or *,- or +
What is a char in c?
What is spark map function?
What does %c do in c?
Why is c so important?
Why is %d used in c?
What are types of preprocessor in c?
Explain what are bus errors, memory faults, and core dumps?
What is a program flowchart?
what is the basis for selection of arrays or pointers as data structure in a program
What is the use of bitwise operator?
What is equivalent to ++i+++j?