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 ?    13 Yes 1 No

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

Answer / sathsh

unexpected

Is This Answer Correct ?    3 Yes 3 No

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

Answer / soni

compile error

Is This Answer Correct ?    4 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

i need all types of question paper releted to "c" and other language.

0 Answers  


How many ways are there to swap two numbers without using temporary variable? Give the each logic.

9 Answers  


Sir,please help me out with the code of this question. Write an interactive C program that will encode or decode multiple lines of text. Store the encoded text within a data file, so that it can be retrieved and decoded at any time. The program should include the following features: (a) Enter text from the keyboard, encode the text and store the encoded text in a data file. (b) Retrieve the encoded text and display it in its encoded form. (c) Retrieve the encoded text, decode it and then display the decoded text. (d) End the computation. Test the program using several lines of text of your choice.

0 Answers  


void main() { int i=5; printf("%d",i++ + ++i); }

21 Answers   ME,


Tell me what is null pointer in c?

0 Answers  






Is c is a low level language?

0 Answers  


What's the total generic pointer type?

0 Answers  


Write a program that accepts a string where multiple spaces are given in between the words. Print the string ignoring the multiple spaces. Example: Input: “ We.....Are....Student “ Note: one .=1 Space Output: "We Are Student"

6 Answers   IBM,


Write a program to print this triangle: * ** * **** * ****** * ******** * ********** Don't use printf statements;use two nested loops instead. you will have to use braces around the body of the outer loop if it contains multiple statements.

6 Answers   Wipro,


What is main () in c?

0 Answers  


Can 'this' pointer by used in the constructor?

0 Answers  


18)struct base {int a,b; base(); int virtual function1(); } struct derv1:base{ int b,c,d; derv1() int virtual function1(); } struct derv2 : base {int a,e; } base::base() { a=2;b=3; } derv1::derv1(){ b=5; c=10;d=11;} base::function1() {return(100); } derv1::function1() { return(200); } main() base ba; derv1 d1,d2; printf("%d %d",d1.a,d1.b) o/p is a)a=2;b=3; b)a=3; b=2; c)a=5; b=10; d)none 19) for the above program answer the following q's main() base da; derv1 d1; derv2 d2; printf("%d %d %d",da.function1(),d1.function1(),d2.function1 ()); o/p is a)100,200,200; b)200,100,200; c)200,200,100; d)none 20)struct { int x; int y; }abc; you can not access x by the following 1)abc-->x; 2)abc[0]-->x; abc.x; (abc)-->x; a)1,2,3 b)2&3 c)1&2 d)1,3,4

1 Answers  


Categories