What will be the output of the following program
#include<stdio.h>
void main()
{
int i=20;
i-=i+++++i++;
printf("%d",i);
}
Answers were Sorted based on User's Feedback
Answer / suji
THE PROGRAM DOES NOT RETURN ANY THING.. IT WILL SHOW THE ERROR
| Is This Answer Correct ? | 10 Yes | 2 No |
Answer / shajitha
Answer will be 42.
i++ =20
i+++=20+
i+++++i=20+22
i+++++i++=42
| Is This Answer Correct ? | 7 Yes | 6 No |
Answer / j mahesh
i=20
i++ + ++i =20 + 21=41
i-=41
i=i-41 =20-41
i= -21
| Is This Answer Correct ? | 4 Yes | 4 No |
Answer / anil kumar singh
this program depend on compiler dos turbo3 cpp
error msg:Lvalue required
| Is This Answer Correct ? | 0 Yes | 1 No |
out put of printf(ā%dā,printf(ram));
Explain what are the __date__ and __time__ preprocessor commands?
How do I read the arrow keys? What about function keys?
If null and 0 are equivalent as null pointer constants, which should I use?
char ch=10;printf("%d",ch);what is the output
Write a program to check whether a number is prime or not using c?
with out using main how to execute the program?
is it possible to create your own header files?
in one file global variable int i; is declared as static. In another file it is extern int i=100; Is this valid ?
How does the assert() function work?
write a Program to dispaly upto 100 prime numbers(without using Arrays,Pointer)
26 Answers ADITI, iFlex, Infosys, Oracle, TCS, Unicops, Wipro,
What are the different properties of variable number of arguments?