Can we use break statement in nested loops?

So will use the break statement with the if condition which compares the key with array elements as shown below: Nested Loops: We can also use break statement while working with nested loops. If the break statement is used in the innermost loop. The control will come out only from the innermost loop.
For More Information Please Refer:


You May Also Like to Read: