I need a program in java

If a program run in for loop than that program doesn't run in while loop. Or if that same program run in while loop that doesn't run in for loop. (these two condition will satisfy in one program)

14th Aug 2022, 7:25 AM
Prince Raj
2 Answers
+ 2
If I understand what you want correctly, you could add a boolean condition in each loop that once the loop is used, the boolean changes and doesn't allow the next loop to execute.
14th Aug 2022, 10:56 AM
Ausgrindtube - avatar
+ 2
Loops will be covered in the sololearn Java course: https://www.sololearn.com/Course/Java/?ref=app It is not clear to me what you try to achieve.
14th Aug 2022, 8:42 AM
Lisa - avatar