what is output?
main()
{
#define SQR(x) x++ * ++x
int i = 3;
printf("
%d %d
",SQR(i),i * SQR(i));
}
a)9 27
b)35 60
c)20 60
d)15 175

Answers were Sorted based on User's Feedback



what is output? main() { #define SQR(x) x++ * ++x int i = 3; printf(" %d..

Answer / harichandana

b

Is This Answer Correct ?    5 Yes 3 No

what is output? main() { #define SQR(x) x++ * ++x int i = 3; printf(" %d..

Answer / lalit

b) 35,60

Is This Answer Correct ?    3 Yes 1 No

what is output? main() { #define SQR(x) x++ * ++x int i = 3; printf(" %d..

Answer / aspirant

c

Is This Answer Correct ?    0 Yes 0 No

what is output? main() { #define SQR(x) x++ * ++x int i = 3; printf(" %d..

Answer / kundan

Can anyone please explain it ????

Is This Answer Correct ?    0 Yes 0 No

what is output? main() { #define SQR(x) x++ * ++x int i = 3; printf(" %d..

Answer / anil patil

b) 35 60

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More C Interview Questions

What is the use of f in c?

0 Answers  


what is the difference between class and unio?

0 Answers   HCL, Wipro,


sir i got 146 correct question & i have also the advantage of height so will they consider my marks as 146+3=149.can any body tell me how they consider my height marks.

1 Answers  


program to find the roots of a quardratic equation

1 Answers  


Write a program to swap two numbers without using third variable in c?

0 Answers  






.main() { char *p = "hello world!"; p[0] = 'H'; printf("%s",p); }

0 Answers   Wilco,


What is difference between static and global variable in c?

0 Answers  


Why clrscr is used after variable declaration?

0 Answers  


What is a good way to implement complex numbers in c?

0 Answers  


Reverse the bit order in a single macro. eg. i/p = 10010101 --> o/p = 10101001

2 Answers  


What is static volatile in c?

0 Answers  


There are 3 baskets of fruits with worng lables,one basket has apple,another basket has orange,another has combination of apple and orange,what is the least way of interchange the lables.

15 Answers   Cisco, Google, MBT,


Categories