main()
{
int i=0;
while(+(+i--)!=0)
i-=i++;
printf("%d",i);
}
Answer Posted / furquan
Here what happens is :
while(+(+i--)!=0)
i = 0
so 0 != 0 is false hence condition for while fails. Now
there is also a post decrement operator. So value of i turns
out to be -1. and that is which is printed.
| Is This Answer Correct ? | 6 Yes | 0 No |
Post New Answer View All Answers
c program to compute AREA under integral
How many types of operators are there in c?
Take an MxN matrice from user and then sum upper diagonal in a variable and lower diagonal in a separate variables. Print the result
shorting algorithmS
What is the difference between scanf and fscanf?
Is it possible to use curly brackets ({}) to enclose single line code in c program?
Explain how can you be sure that a program follows the ansi c standard?
What does the error message "DGROUP exceeds 64K" mean?
Why do we use header files in c?
Is c++ based on c?
What is pass by reference in functions?
How to throw some light on the b tree?
‘SAVEPOINT’ and ‘ROLLBACK’ is used in oracle database to secure the data comment. Give suitable examples of each with sql command.
What are header files in c?
Write the program with at least two functions to solve the following problem. The members of the board of a small university are considering voting for a pay increase for their 10 faculty members. They are considering a pay increase of 8%. Write a program that will prompt for and accept the current salary for each of the faculty members, then calculate and display their individual pay increases. At the end of the program, print the total faculty payroll before and after the pay increase, and the total pay increase involved.