what is the use of using for loop as "for(;;)"?

Answers were Sorted based on User's Feedback



what is the use of using for loop as "for(;;)"?..

Answer / san

Infinite loop

Is This Answer Correct ?    11 Yes 2 No

what is the use of using for loop as "for(;;)"?..

Answer / lalitha

Evaluates the whole loop to be true infinite

Is This Answer Correct ?    8 Yes 1 No

what is the use of using for loop as "for(;;)"?..

Answer / balajisrikanth

for(;;) - is an infinite loop

Is This Answer Correct ?    5 Yes 0 No

what is the use of using for loop as "for(;;)"?..

Answer / piyush

for gating infinite time looping use for(;;),second approach
same as while(true).

Is This Answer Correct ?    4 Yes 0 No

what is the use of using for loop as "for(;;)"?..

Answer / arun n patil

for using first inisilization;second test counter;third
increment/decrement
int i;
syntax: for(i=0;i<=100;i++)

Is This Answer Correct ?    2 Yes 2 No

Post New Answer

More C++ Code Interview Questions

Question 1: Implement a base class Appointment and derived classes Onetime, Daily, Weekly, and Monthly. An appointment has a description (for example, “see the dentist”) and a date and time. Write a virtual function occurs_on(int year, int month, int day) that checks whether the appointment occurs on that date. For example, for a monthly appointment, you must check whether the day of the month matches. Then fill a vector of Appointment* with a mixture of appointments. Have the user enter a date and print out all appointments that happen on that date. *This Should Be Done IN C++

0 Answers  


How reader and writer problem was implemented and come up with effective solution for reader and writer problem in case we have n readers and 1 writer.

6 Answers   Microsoft, NetApp,


write a program to perform generic sort in arrays?

0 Answers  


How can I Draw an ellipse in 3d space and color it by using graph3d?

0 Answers  


using repetition structure. Write a c program that will accept five numbers. The program should count and output the total count of even numbers and total count of add numbers.

2 Answers  


U hv to enter a range from a and b and search hw many no. of times a pattern n. occurs between the range a and b. Eg :i/p:enter range :0 100 Enter pattern: 13 o/p: the no. times 13 occurred betwwn 0 to 100:1 Eg :i/p:enter range :100 1000 Enter pattern: 13 o/p: the no. times 13 occurred betwwn 100 to 1000: (in this 13,113,131,132,133&#8230;139,213,313,&#8230;913 all these will be counted)

0 Answers  


main(){int a=5,b 10,c=2, d;a=b c;d=++a=(--c)*2; printf("%d%d%d%d,a,b,c,d; return o;}

1 Answers  


write a program using 2 D that searches a number and display the number of items 12 inputs values input 15,20, 13, 30, 38, 40,16, 18, 20 ,18 ,20 enter no. to search : 20

0 Answers  


1.program to add any two objects using operator overloading 2.program to add any two objects using constructors 3.program to add any two objects using binary operator 4.program to add any two objects using unary operator

2 Answers   IBM,


1. Write a program using one dimensional array that calculates the sum and average of the five input values from the keyboard and prints the calculated sum and average.

2 Answers  


void main() { int i,j=2; for(i=0;i<3;i++) if(j=i) cout<<"Lotus "; else cout<<"Rose "; } Its result is Rose Lotus Lotus.. How? Explain it?

2 Answers  


Write a C/C++ program that connects to a MySQL server and checks if the InnoDB plug-in is installed on it. If so, your program should print the total number of disk writes by MySQL.

0 Answers  


Categories