0

void main() { int a=3,b=4,c=6; printf("℅d ℅d ℅d"); getch(); } The output of this program is 6 4 3 why? can anyone explain this?

19th Aug 2016, 6:09 PM
sree lekha
sree lekha - avatar
5 ответов
+ 1
there is no specific order for evaluation of those variables ,result might vary for each compiler . if u want that in line then u can do it as follows printf("%d %d %d",a,b,c);
19th Aug 2016, 9:27 PM
sumit kamble
sumit kamble - avatar
+ 1
no I got one answer like this the variables which we are declared are stored in stack so those will pop out like that
23rd Aug 2016, 1:09 PM
sree lekha
sree lekha - avatar
0
printf("%d %d %d",a,b,c)
19th Aug 2016, 8:56 PM
RAHUL KULKARNI
RAHUL KULKARNI - avatar
0
getch() is taking the character value so the output is like tht
23rd Aug 2016, 10:48 AM
Kumar Suman
Kumar Suman - avatar
0
state the output produced by the printf statement is printft[%d%d%d",12,12.5,345];
15th Aug 2017, 3:37 PM
azvl ngaitlawma
azvl ngaitlawma - avatar