☰
×
Home
◈ Introduction
C - Data Types IQ
◈ C Data Type Tricky - I
◈ C Data Type Tricky - II
◈ C Data Type Tricky - III
◈ C Data Type Tricky - IV
◈ C Data Type Tricky - V
C - Operators IQ
◈ C Operators Tricky - I
◈ C Operators Tricky - II
◈ C Operators Tricky - III
Choose the Correct
◈ Choose the Correct Ans - I
◈ Choose the Correct Ans- II
◈ Choose the Correct Ans - III
◈ Choose the Correct Ans - IV
◈ Choose the Correct Ans - V
◈ Choose the Correct Ans - VI
Find Output - Tricky
◈ C Pgm Tricky Questions I
◈ C Pgm Tricky Questions II
◈ C Pgm Tricky Questions III
◈ C Pgm Tricky Questions IV
◈ C Pgm Tricky Questions V
◈ C Pgm Tricky Questions VI
◈ C Pgm Tricky Questions VII
◈ C Pgm Tricky Questions VIII
◈ C Pgm Tricky Questions IX
C - General IQ
◈ General C Questions I
◈ General C Questions II
◈ General C Questions III
◈ General C Questions IV
◈ General C Questions V
◈ General C Questions VI
◈ General C Questions VII
Home
About
Consulting
Training
Tutorial
Interview Questions
Contact
Interview Questions
C Tricky - Find Output
Home
C Interview Questions
◈ Introduction
C Data Types Tricky Questions
◈ C Data Type Tricky Questions I
◈ C Data Type Tricky Questions II
◈ C Data Type Tricky Questions III
◈ C Data Type Tricky Questions IV
◈ C Data Type Tricky Questions V
C Operators Interview Questions
◈ C Operators Tricky Questions I
◈ C Operators Tricky Questions II
◈ C Operators Tricky Questions III
Choose the Correct Answer
◈ Choose the Correct Answer I
◈ Choose the Correct Answer II
◈ Choose the Correct Answer III
◈ Choose the Correct Answer IV
◈ Choose the Correct Answer V
◈ Choose the Correct Answer VI
Find Output - Tricky C Program
◈ C Programs Tricky Questions I
◈ C Programs Tricky Questions II
◈ C Programs Tricky Questions III
◈ C Programs Tricky Questions IV
◈ C Programs Tricky Questions V
◈ C Programs Tricky Questions VI
◈ C Programs Tricky Questions VII
◈ C Programs Tricky Questions VIII
◈ C Programs Tricky Questions IX
General C Interview Questions
◈ General C Questions I
◈ General C Questions II
◈ General C Questions III
◈ General C Questions IV
◈ General C Questions V
◈ General C Questions VI
◈ General C Questions VII
C Programming Interview Questions
C Tricky Questions - Find Output VIII
« Prev
Next »
C Tricky Questions - Find Output
Program 141 #include
int main() { int a=5,b=4,c=9; *(a>b?&a:&b)=(a+b)>c; printf("%d %d\n",a,b); } Program 142 #define ONE TWO # define TWO ONE Int main() { Program 143 #include
int main() { int a=printf("00"); printf("%d\n",a); } Program 144 #include
int main() { int a,b,c; printf("%d\n",scanf("%d%d%d",&a,&b,&c)); } Program 145 #include
int main() { printf("%p\n",main); } Program 146 #include
main() { int *p=200000; printf("p=%p\n",p); } Program 147 #include
int main() { char *x; x="SAFRAN"; printf("%s\n",x+3); printf("%d"+2,123456); printf("\n"); } Program 148 #include
int main() { int a=146,b=256; a^=b^=a^=b; printf("%d %d\n",a,b); } Program 149 #include
int main() { char *p="0123456789"; char *ptr=p+5; printf("%s %s\n",ptr,p); } Program 150 #include
#define MAX 20 main() { int i; for(i=0; i
struct student { char *c; }; main() { struct student m; struct student *s=&m; (*s).c="hello"; printf("%s\n",m.c); } Program 152 #include
main() { char arr[]="americanMegatrends"; char *p=arr; *p++; printf("%c",*p); getchar(); } Program 153 #include
main() { int a=5; printf("%d %d..%d..%d\n",a++,a++,a++,++a); } Program 154 #include
main() { int a=320; char *ptr; ptr=(char*)&a; printf("%d\n",*ptr); } Program 155 #include
main() { int a=0,i=0,b; for(i=0;i<5;i++) { a++; continue; } printf("a=%d\n",a); } Program 156 #include
main() { int i,j; for(i=0;i<5;i++) { for(j=0;j<4;j++) { if(i>1) break; } printf("hi\n"); } } Program 157 #include
main() { if(7 & 8) printf("brave\n"); if((~7 & 0x000f)==8) printf("coward\n"); } Program 158 #include
struct l { int x; int y; }; main() { struct l p[]={1,2,3,4,5}; struct l *q=p; printf("%d...%d\n",(*q)->x,p.x); } Program 159 #include
main() { void *p(); int *q(); int *r(); p=clrscr; q=getchar; r=puts; (*p)(); (*r)(); (*q)(); } Program 160 #include
main() { printf("%d"); }
« Prev
Next »
Helpful Links
Sateeshkg Home
Interview Questions
Corporate Training
Recommended Books
Linux Consulting
Apply for Job Assistance
If you have any queries please email us at
info@motionzen.com