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 / puja
THE ANSWER WILL BE
20 20 22 22
BECAUSE THE FIRST VALUE IS K=20 THEN IT WILL BE THE SAME
20 DUE TO K++, NOW THE VALUE WILL BE INCREMENTED & WILL BE
21, THEN ++K, MEANS THE VALUE WILL BE +1 THEN IT WILL BE 22
& LAST K WILL BE SAME 22.
| Is This Answer Correct ? | 3 Yes | 5 No |
Post New Answer View All Answers
Why cant I open a file by its explicit path?
What is a program flowchart and how does it help in writing a program?
In C language, a variable name cannot contain?
how to make a scientific calculater ?
What are inbuilt functions in c?
What are header files in c?
What does c mean in basketball?
Where define directive used?
How to write a code for implementing my own printf() and
scanf().... Please hep me in this... I need a guidance...
Can you give an coding for c... Please also explain about
the header files used other than #include
What is the main difference between calloc () and malloc ()?
What is the use of ?
What is a pointer in c?
What is declaration and definition in c?
What is a keyword?
What is array in C