#include<stdio.h>
void main()
{
int =1;
printf("%d%d%d",a++,++a,++a);
}

Answers were Sorted based on User's Feedback



#include<stdio.h> void main() { int =1; printf("%d%d%d",a++,++a,++a); }..

Answer / sravani

i got the answer 1,3,4

Is This Answer Correct ?    5 Yes 1 No

#include<stdio.h> void main() { int =1; printf("%d%d%d",a++,++a,++a); }..

Answer / drashti

3

Is This Answer Correct ?    0 Yes 0 No

#include<stdio.h> void main() { int =1; printf("%d%d%d",a++,++a,++a); }..

Answer / stephen john

i got the answer is 3,4,4.
why?

Is This Answer Correct ?    4 Yes 6 No

Post New Answer

More C Interview Questions

Are there namespaces in c?

0 Answers  


What will be the result of the following program? main() { char p[]="String"; int x=0; if(p=="String") { printf("Pass 1"); if(p[sizeof(p)-2]=='g') printf("Pass 2"); else printf("Fail 2"); } else { printf("Fail 1"); if(p[sizeof(p)-2]=='g') printf("Pass 2"); else printf("Fail 2"); } } a) Pass 1, Pass 2 b) Fail 1, Fail 2 c) Pass 1, Fail 2 d) Fail 1, Pass 2 e) syntax error during compilation

10 Answers   IBM,


Is null always equal to 0(zero)?

0 Answers  


What are the advantages and disadvantages of pointers?

0 Answers  


What are external variables in c?

0 Answers  






Explain what is the difference between #include and #include 'file' ?

0 Answers  


Can 'this' pointer by used in the constructor?

0 Answers  


Why is sprintf unsafe?

0 Answers  


logic for generating all the combinations of the any number of given letters. ex::::::::: if a,b,c,d are given the o/p should be abcd,dcba,dbac,bcad,................ 4*3*2*1 combinations............

2 Answers   Infosys,


write a code for large nos multilication (upto 200 digits)

2 Answers   Persistent,


a=0; b=(a=0)?2:3; a) What will be the value of b? why b) If in 1st stmt a=0 is replaced by -1, b=? c) If in second stmt a=0 is replaced by -1, b=?

6 Answers   Geometric Software,


#include<stdio.h> int SumElement(int *,int); void main(void) { int x[10]; int i=10; for(;i;) { i--; *(x+i)=i; } printf("%d",SumElement(x,10)); } int SumElement(int array[],int size) { int i=0; float sum=0; for(;i<size;i++) sum+=array[i]; return sum; } output?

5 Answers   Ramco,


Categories