Wednesday 9 January 2008

Huge collection of c programming questions with solutions

53. For the following C program
void main()
{
unsigned char c;
for(c=0;c!=256;c=c+2)
printf("%d",c);
getch();
}


(a) 127
(b) 128
(c) 256
(d) infinitely
Ans: (d)

54. For the following program
int i;
i=0;
repeat
i=i+1; <====== PASCAL PROGRAM
print i;
until(i<10)
end
No. of times the loop is executed?
55. For the following program
Convert (int A,var ,int B;int c)
{A=10;
B=4-;
C=120;
}
Convert (

No comments:

Post a Comment