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 |
wap in c to accept a number display the total count of digit
main() { int *ptr=(int*)malloc(sizeof(int)); *ptr=4; printf("%d",(*ptr)+++*ptr++); }
Explain what is a const pointer?
9.how do you write a function that takes a variable number of arguments? What is the prototype of printf () function? 10.How do you access command-line arguments? 11.what does ‘#include<stdio.h>’ mean? 12.what is the difference between #include<> and #include”…”? 13.what are # pragma staments? 14.what is the most appropriate way to write a multi-statement macro?
Reverse the bit order in a single macro. eg. i/p = 10010101 --> o/p = 10101001
Suppose I want to write a function that takes a generic pointer as an argument and I want to simulate passing it by reference. Can I give the formal parameter type void **, and do something like this? void f(void **); double *dp; f((void **)&dp);
the number of measuring units from a arbitrary starting point in a record area or control block to some other point a) branching b) recording pointer c) none d) offset
What is double pointer?
‘ C’ PROGRAME TO SHOW THE TYPE OF TRANGLE BY ACCEPTING IT’S LENGTH .
can anyone please tell me wat is backlogs... i was looking for the job openings where i read this.. eligibility criteria minimum 70% in degree without backlogs. is that arrear.. if so is it standing arrear or history of arrears... please help me...
11 Answers CTS, Indian Navy, L&T, Microsoft, SSB, TCE, TCS,
read a number & print all its devisors using c-program?
how we can say java is platform independent, while we require JVM for that particular Operating System?