While loop: It is one of Java's three control structures employed for looping. The other two are: do loop and for loop. The while loop comprises of a Boolean expression and a loop body. The condition is tested prior to the loop body is entered for the very first time and re-tested each and every time the end of the body is finished. The loop terminates whenever the condition provides the output false. Statements in the loop body might be performed zero or more times.