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
What is build process in c?
in any language the sound structure of that language depends on its a) character set, input/output function, its control structures b) character set, library functions, input/output functions its control structures c) character set, library functions, control sturctures d) character set, operators, its control structures
Explain can static variables be declared in a header file?
What is table lookup in c?
Why we not create function inside function.
What is difference between array and structure in c?
The performance of an operation in several steps with each step using the output of the preceding step a) recursion b) search c) call by value d) call by reference
is it possible to create your own header files?
The number of bytes of storage occupied by short, int and long are a) 2, 2 and 4 b) 2, 4 and 4 c) 4, 4 and 4 d) none
Write a programme using structure that create a record of students. The user allow to add a record and delete a record and also show the records in ascending order.
What should malloc() do?
What would be an example of a structure analogous to structure c?
Explain what is the difference between a string copy (strcpy) and a memory copy (memcpy)? When should each be used?
Why we use int main and void main?
What is c preprocessor mean?