WHAT WILL BE OUTPUT OF BELOW CODE . . AND PLEASE EXPLAIN HOW
IT COME ..
#include<stdio.h>
#include<conio.h>
void main()
{
int k=20;
printf("%d%d%d%d",k,k++,++k,k);
getch();
}
Answer Posted / rajadurai thangaraj
22 21 22 22
stack execution:-
4 ->printf k now k=22
3 ->printf 21 k=k+1 now k=22, k of 1&2 also 22
2 ->k=k+1 printf k now k=21, k of 1 also 21
1 ->printf k now k=20
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
Is it acceptable to declare/define a variable in a c header?
What is a program flowchart and explain how does it help in writing a program?
Explain how can you be sure that a program follows the ansi c standard?
what is a function method?give example?
Give me the code of in-order recursive and non-recursive.
write a program to find out prime number using sieve case?
Explain how can I manipulate strings of multibyte characters?
What is the difference between procedural and declarative language?
How many keywords are there in c?
What is cohesion and coupling in c?
What is the full form of getch?
Tell me what is the purpose of 'register' keyword in c language?
What is the use of #define preprocessor in c?
Want to know how to write a C program that connects to a MySQL server and checks if the InnoDB plug-in is installed on it. If so, your program should print the total number of disk writes by MySQL.
Can you explain what keyboard debouncing is, and where and why we us it? please give some examples