main(){

unsigned int i;

for(i=1;i>-2;i--)

printf("c aptitude");

}

Answers were Sorted based on User's Feedback



main(){ unsigned int i; for(i=1;i>-2;i--) printf("c aptitud..

Answer / susie

Explanation:

i is an unsigned integer. It is compared with a signed
value. Since the both types doesn't match, signed is
promoted to unsigned value. The unsigned equivalent of -2 is
a huge value so condition becomes false and control comes
out of the loop.

Is This Answer Correct ?    11 Yes 2 No

main(){ unsigned int i; for(i=1;i>-2;i--) printf("c aptitud..

Answer / maroti kukade

No output

Is This Answer Correct ?    1 Yes 0 No

Post New Answer

More C Code Interview Questions

print a semicolon using Cprogram without using a semicolon any where in the C code in ur program!!

35 Answers   Tata Elxsi, TCS, VI eTrans,


int aaa() {printf(“Hi”);} int bbb(){printf(“hello”);} iny ccc(){printf(“bye”);} main() { int ( * ptr[3]) (); ptr[0] = aaa; ptr[1] = bbb; ptr[2] =ccc; ptr[2](); }

1 Answers  


Write a program to implement the motion of a bouncing ball using a downward gravitational force and a ground-plane friction force. Initially the ball is to be projected in to space with a given velocity vector

2 Answers  


struct Foo { char *pName; char *pAddress; }; main() { struct Foo *obj = malloc(sizeof(struct Foo)); clrscr(); obj->pName = malloc(100); obj->pAddress = malloc(100); strcpy(obj->pName,"Your Name"); strcpy(obj->pAddress, "Your Address"); free(obj); printf("%s", obj->pName); printf("%s", obj->pAddress); } a. Your Name, Your Address b. Your Address, Your Address c. Your Name Your Name d. None of the above

2 Answers   HCL,


Hi, i have a project that the teacher want a pyramid of numbers in C# or java...when we click a button...the pyramid should be generated in a listbox/or JtextArea...and the pyramid should have the folowing form: 1 232 34543 4567654 567898765 67890109876 7890123210987 890123454321098 90123456765432109 0123456789876543210 Plz help with codes...didn't find anything on the net.

0 Answers  






main() { int c[ ]={2.8,3.4,4,6.7,5}; int j,*p=c,*q=c; for(j=0;j<5;j++) { printf(" %d ",*c); ++q; } for(j=0;j<5;j++){ printf(" %d ",*p); ++p; } }

2 Answers   CSS, Wipro,


main() { char string[]="Hello World"; display(string); } void display(char *string) { printf("%s",string); }

2 Answers   Wipro,


x=2 y=3 z=2 x++ + y++; printf("%d%d" x,y);

2 Answers  


Is this code legal? int *ptr; ptr = (int *) 0x400;

1 Answers  


main() { int i=10; i=!i>14; Printf ("i=%d",i); }

1 Answers  


main() { int i, j; scanf("%d %d"+scanf("%d %d", &i, &j)); printf("%d %d", i, j); } a. Runtime error. b. 0, 0 c. Compile error d. the first two values entered by the user

2 Answers   HCL,


Cau u say the output....?

1 Answers  


Categories