main()
{
intj;
while9j<=10)
{
printf("\n%d",j);
j=j+1;
}
}

Answers were Sorted based on User's Feedback



main() { intj; while9j<=10) { printf("\n%d",j); j=j+1; } }..

Answer / ritesh kumar

Since variable j is not initialised it will contain garbage
value hence the output(imposed on the while loop condition)
may be unexpected ..

Is This Answer Correct ?    12 Yes 1 No

main() { intj; while9j<=10) { printf("\n%d",j); j=j+1; } }..

Answer / sathsh

unexpected

Is This Answer Correct ?    2 Yes 3 No

main() { intj; while9j<=10) { printf("\n%d",j); j=j+1; } }..

Answer / soni

compile error

Is This Answer Correct ?    3 Yes 6 No

main() { intj; while9j<=10) { printf("\n%d",j); j=j+1; } }..

Answer / niranjan kumar niraj

output=9

Is This Answer Correct ?    0 Yes 9 No

Post New Answer

More C Interview Questions

An expression to whose value an operater is applied a) operand b) variable c) constant d) all of the above

0 Answers  


What is the difference between local variable and global variable in c?

0 Answers  


Explain the use of 'auto' keyword

0 Answers  


What will be result of the following program? void myalloc(char *x, int n) { x= (char *)malloc(n*sizeof(char)); memset(x,\0,n*sizeof(char)); } main() { char *g="String"; myalloc(g,20); strcpy(g,"Oldstring"); printf("The string is %s",g); } a) The string is : String b) Run time error/Core dump c) The string is : Oldstring d) Syntax error during compilation e) None of these

3 Answers   IBM,


Which header file should you include if you are to develop a function which can accept variable number of arguments?

0 Answers   TCS, TISL,






what is the code to display color fonts in the output?

1 Answers  


What is malloc() function?

0 Answers  


Is the exit() function same as the return statement? Explain.

0 Answers   Agilent, ZS Associates,


How to write c functions that modify head pointer of a linked list?

0 Answers  


what is the difference between #include<> and #include”…”?

5 Answers  


How is pointer initialized in c?

0 Answers  


void main(){ int a; a=1; while(a-->=1) while(a-->=0); printf("%d",a); }

0 Answers  


Categories