Which of the following is not an infinite loop ?
a.while(1){
....
}
b.for(;;){
...
}
c.x=0;
do{
/*x unaltered within theloop*/
...
}while(x==0);
d.# define TRUE 0
...
while(TRUE){
....
}
Answers were Sorted based on User's Feedback
Answer / krishna kumar
ya deepa is ryt.
true here equals zero...which is false.
so the correct answer is D.
| Is This Answer Correct ? | 23 Yes | 3 No |
Answer / balu
yes.. deepa is right.. all are infinite loops except d. so d
is the answer
| Is This Answer Correct ? | 7 Yes | 1 No |
Answer / vaibhav
it's 'b'
becoz for for loop we initialise atleast one statement
| Is This Answer Correct ? | 2 Yes | 13 No |
what is the use of ~ in c lang?????
How to write in a function declaration and in function call in which the function has 'n' number of varible or arguments?
What is realloc in c?
write a c program for print your name .but,your name may be small letter mean print a capital letter or your name may be capital letter mean print a small letter .example \\enter ur name : sankar The name is: SANKAR (or) enter your name:SAnkar The name is:saNKAR
Write a program to replace n bits from the position p of the bit representation of an inputted character x with the one's complement. Method invertBit takes 3 parameters x as input character, p as position and n as the number of positions from p. Replace n bits from pth position in 8 bit character x. Then return the characters by inverting the bits.
c program to arrange digits in a no in ascending and descending order
write a c program for print your name .but,your name may be small letter mean print a capital letter or your name may be capital letter mean print a small letter .example \\enter ur name : sankar The name is: SANKAR (or) enter your name:SAnkar The name is:saNKAR
What is substring in c?
Write a C program where input is: "My name is xyz". output is: "xyz is name My".
C,c++, Java is all are structural oriented or procedure oriented language..?
What are the different flags in C? And how they are useful? And give example for each in different consequences?
#include <stdio.h> int main() { int i; for (i=0;i<3;++i) { fork();fork(); } } How many processes are created when running this program (including the initial one)? Explain ؟؟؟