C Programming Loop Constructs
In C programming, the loop that is executed at least once (even if the condition is false) is called ______ loop.
سی پروگرامنگ میں ، لوپ جو کم از کم ایک بار انجام دیا جاتا ہے (یہاں تک کہ اگر حالت غلط ہے) کو ______ لوپ کہا جاتا ہے۔
Answer: do-while
Explanation
In a do-while loop, the body executes first, and the condition is checked afterward, ensuring it runs at least once.
This differs from for and while loops, which check the condition before executing.
This question appeared in
Past Papers (5 times)
ETEA 25 Years Past Papers Subject Wise (Solved) (2 times)
ETEA Past Papers (1 times)
KPK Teacher Past Papers SST PST CT TT PET (2 times)
This question appeared in
Subjects (1 times)
COMPUTER (1 times)
Related MCQs
- Which loop is suitable to use in situations where the programmer does not know the number of time the body of the loop will be executed?
- Which loop is preferred to use when the programmer knows in advance how many times the body of the loop will be executed?
- The statement, when used inside the body of a loop, causes termination of the loop without terminating the program is _______?
- What is the purpose of a loop in programming?
- A Loop wit in the loop is called?
- A square loop of wire lies in the plane of the page. A decreasing magnetic field is directed into page. The induced current in the loop is ____?
- Who states that any closed loop path, the sum of the length elements times of the magnetic field in the direction of the length element is equal to the permeability times the electric current enclosed in the loop?
- Which loop structure is not available in C programing?
- The idiom TO BE IN THE LOOP means:
- What is the time complexity of a C++ program with a nested for-loop?