Sometimes we want a C++ program to repeat something over and over again, a loops is used to make a program do something more than one time thats called loops. C++ supports following types of loops:
C Language loop Comparison - All loops constructs C++ repeat a set of condition remains true. This specified condition is generally referred to as a loop control. For all three loop statement, a true condition is any nonzero value. A zero value indicates a false condition.
Every loop has its elements that control and govern its execution. Generally, a loop has four elements that have different purpose. These elements are as given below :