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 / vishwanath pillay
The answer will be :-
20, 21, 21, 21
At the start the value is initialized to 20.
since the line:-
printf("%d%d%d%d",k,k++,++k,k);
Answer:-- 20, 21, 21, 21
| Is This Answer Correct ? | 0 Yes | 11 No |
Post New Answer View All Answers
Is c weakly typed?
How can I check whether a file exists? I want to warn the user if a requested input file is missing.
How many loops are there in c?
How can you determine the size of an allocated portion of memory?
What is the use of f in c?
What is the default value of local and global variables in c?
Explain what are its uses in c programming?
Where are local variables stored in c?
Write a program for finding factorial of a number.
Explain what are the different data types in c?
How can I ensure that integer arithmetic doesnt overflow?
What is c language used for?
When should a type cast be used?
program to find out date after adding 31 days to a date in the month of febraury also consider the leap year
Is c# a good language?