Using the while Loop : While « JSP « Java Tutorial






<HTML>
  <HEAD>
    <TITLE>Using the while Loop</TITLE>
  </HEAD>

  <BODY>
    <H1>Using the while Loop</H1>
    <%
        int value = 5;

        while (value > 0) {
            out.println("The value is now " + value-- + ".<BR>");
        }
    %>
  </BODY>
</HTML>








23.9.While
23.9.1.Using the while Loop
23.9.2.Finding a Factorial
23.9.3.Finding Reciprocals