Java Tutorial #10 — Loop logic / intro

Topics Discussed: While loops, do_while loops, counter controlled loops, loop syntax, loop scoping Source Code For Lesson 10: import java.util.Scanner; class Jtutorial1 { public static void main(String args[]){ Scanner input = new Scanner(System.in); int i=0;//initialize a new variable for use as a counter while(i < 10){//While the variable is less than 10 System.out.println(i);//Print the current... » read more

Programming Problem #1 — starting off slow

In his challenge I ask that you do the following things: Create a program that will: Use loops to complete the tasks below Print out a list of all the numbers that meet the following criteria, one item per line. Are either: Prime, or Multiples of 3, or 8, but not both 3 and 8,... » read more