1.

Which of the following is an entry-controlled loop?(a) for(b) while(c) do-while(d) both while and forI have been asked this question during a job interview.This intriguing question comes from C++ Concepts in chapter Basics Concepts of C++ of C++

Answer»

The correct OPTION is (d) both while and for

The BEST I can explain: Both while and for LOOPS are called entry controlled loop because in both of them the termination condition is checked before we enter the BODY of the loop hence they are called entry controlled loop.



Discussion

No Comment Found

Related InterviewSolutions