/* Author : Michael Robinson Program : whileLoopDO.java Purpose : To present the do while loop Updated : Jan 29, 2099 */ public class whileLoopDO { public static void doWhileLoop() { int temperature = 50; int humidity = 10; int altitude = -5; do { System.out.println( "this line prints at least ONCE" ); System.out.println( "altitude is " + altitude ); } while( ((temperature > 0) && (humidity < 100) && (altitude>0))|| ((temperature < 100) && (humidity > 0) && (altitude>0)) ); }//end public static void theWhileLoop() public static void main( String arg[] ) { doWhileLoop(); }//end public static void main( String arg[] ) }//end public class whileLoop