User Tools

Site Tools


number_cube

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
number_cube [2019/09/13 13:38] frchrisnumber_cube [2019/09/13 13:40] frchris
Line 15: Line 15:
     {     {
         Scanner kb = new Scanner(System.in);         Scanner kb = new Scanner(System.in);
-        String in = "";+        String input = "";
         System.out.println("Welcome to the Number Rolling Tester");         System.out.println("Welcome to the Number Rolling Tester");
         // make 2 new number cubes         // make 2 new number cubes
         do          do 
         {         {
 +            // roll the cubes and return the sum of the 2 dice
 +            
             System.out.println("Press return to roll, type Q to quit");             System.out.println("Press return to roll, type Q to quit");
-            in = kb.nextLine();+            input = kb.nextLine();
         }         }
-        while ( ! in.equalsIgnoreCase("Q") );+        while ( ! input.equalsIgnoreCase("Q") );
         System.out.println("Thanks for testing this out.");         System.out.println("Thanks for testing this out.");
  
number_cube.txt · Last modified: 2019/09/16 14:32 by frchris

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki