Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

differentiate built-in functions and user – defined functions.

1098


What is structure padding and packing in c?

1077


code for find determinent of amatrix

1972


What is variable declaration and definition in c?

903


Difference between linking and loading?

1117


What is time null in c?

1080


How will you find a duplicate number in a array without negating the nos ?

2138


what do you mean by inline function in C?

1062


How can I recover the file name given an open stream?

1030


How to check whether string is a palindrome, WITHOUT USING STRING FUNCTIONS?

16799


formula to convert 2500mmh2o into m3/hr

1001


What language is lisp written in?

1272


Write a program to print "hello world" without using a semicolon?

1071


What is size of union in c?

1028


What is spaghetti programming?

1145