Learn how to program While and For statements (loop statements) when programming in Java. This tutorial uses Java 1.6 with NetBeans 5.5.1 beta.