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();
}

Answers were Sorted based on User's Feedback



WHAT WILL BE OUTPUT OF BELOW CODE . . AND PLEASE EXPLAIN HOW IT COME .. #include<stdio.h>..

Answer / pratik

but how answer came ? ?

Is This Answer Correct ?    0 Yes 3 No

WHAT WILL BE OUTPUT OF BELOW CODE . . AND PLEASE EXPLAIN HOW IT COME .. #include<stdio.h>..

Answer / vijay

20 21 20 20

Is This Answer Correct ?    2 Yes 7 No

WHAT WILL BE OUTPUT OF BELOW CODE . . AND PLEASE EXPLAIN HOW IT COME .. #include<stdio.h>..

Answer / 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

WHAT WILL BE OUTPUT OF BELOW CODE . . AND PLEASE EXPLAIN HOW IT COME .. #include<stdio.h>..

Answer / shashikant

20,20,22,22

Is This Answer Correct ?    2 Yes 15 No

WHAT WILL BE OUTPUT OF BELOW CODE . . AND PLEASE EXPLAIN HOW IT COME .. #include<stdio.h>..

Answer / priyanka

20,20,21,20

Is This Answer Correct ?    5 Yes 20 No

Post New Answer

More C Interview Questions

What are reserved words with a programming language?

0 Answers  


Why c is called a middle level language?

0 Answers  


Explain the concept and use of type void.

0 Answers  


. A database table called PERSON contains the fields NAME, BASIC and HRA. Write a computer program to print a report which employee name and total salary for those employees whose total salary is more than 10,000. Total Salary = BASIC + HRA. At the end, the program should also print the total number of employees whose total salary is more than 10,000.

1 Answers  


What's the best way of making my program efficient?

0 Answers   Celstream,


a=0; while(a<5) printf("%d\n",a++); how many times does the loop occurs? a.infinite b.5 c.4 d.6

7 Answers   TCS,


Write a C/C++ program that connects to a MySQL server and displays the global TIMEZONE.

0 Answers  


What does 4d mean in c?

0 Answers  


What is the usage of the pointer in c?

0 Answers  


#define f(g,h) g##h main O int i=0 int var=100 ; print f ("%d"f(var,10));} wat would be the output??

0 Answers  


how to convert binary to decimal and decimal to binary in C lanaguage

7 Answers   BPO, Far East Promotions, IBM, RBS,


C program code int zap(int n) { if(n<=1)then zap=1; else zap=zap(n-3)+zap(n-1); } then the call zap(6) gives the values of zap [a] 8 [b] 9 [c] 6 [d] 12 [e] 15

6 Answers   TCS, Wipro,


Categories