void main()

{

int i=5;

printf("%d",i+++++i);

}

Answers were Sorted based on User's Feedback



void main() { int i=5; printf("%d",i+++++i); }..

Answer / susie

Answer :

Compiler Error

Explanation:

The expression i+++++i is parsed as i ++ ++ + i which is an
illegal combination of operators.

Is This Answer Correct ?    4 Yes 3 No

void main() { int i=5; printf("%d",i+++++i); }..

Answer / ashi rathore

Ans is 11, as i+++++i can be written as i++ + ++i.
i++ =5
++i = 6
then 5 + 6 = 11

Is This Answer Correct ?    0 Yes 1 No

void main() { int i=5; printf("%d",i+++++i); }..

Answer / lucky varshney

i=6

Is This Answer Correct ?    0 Yes 5 No

Post New Answer

More C Code Interview Questions

How to count a sum, when the numbers are read from stdin and stored into a structure?

1 Answers  


main() { int i=300; char *ptr = &i; *++ptr=2; printf("%d",i); }

4 Answers   CSC,


Is the following code legal? struct a { int x; struct a b; }

1 Answers  


{ int *ptr=(int*)malloc(sizeof(int)); *ptr=4; printf("%d",(*ptr)+++*ptr++); }

4 Answers  


main() { int i=-1,j=-1,k=0,l=2,m; m=i++&&j++&&k++||l++; printf("%d %d %d %d %d",i,j,k,l,m); }

1 Answers  






how can i search an element in an array

2 Answers   CTS, Microsoft, ViPrak,


main() { int i=0; while(+(+i--)!=0) i-=i++; printf("%d",i); }

9 Answers   CSC, GoDB Tech, IBM,


write a c program to Create a mail account by taking the username, password, confirm password, secret_question, secret_answer and phone number. Allow users to register, login and reset password(based on secret question). Display the user accounts and their details .

2 Answers  


write a c-program to display the time using FOR loop

3 Answers   HCL,


Write a program that reads a dynamic array of 40 integers and displays only even integers

2 Answers  


Is it possible to type a name in command line without ant quotes?

1 Answers   Excel, Infosys,


What is the problem with the following code segment? while ((fgets(receiving array,50,file_ptr)) != EOF) ;

1 Answers  


Categories