Advertisement
Guest User

Untitled

a guest
Jan 23rd, 2017
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. public void numberSquare(int min, int max){
  2.     for(int lines = min; lines <= max; lines ++){
  3.         System.out.println();   
  4.         for(int num = min; num <= max; num++){
  5.             if(num + lines > max){
  6.                     System.out.print(num);
  7.             }
  8.             else {System.out.print(num + lines);
  9.           
  10.                  }
  11.         }
  12.     }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement