Guest User

Untitled

a guest
Dec 13th, 2017
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.45 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. public class Zadanie_7 {
  4.  
  5. public static void main(String[] args) {
  6. int a;
  7. System.out.println("Podaj liczbe");
  8. Scanner scanner = new Scanner(System.in);
  9. a = scanner.nextInt();
  10. int [][] tablica = new int[a][a];
  11. for (int i = 1; i <= a; i++) {
  12. for (int j = 1; j <= a; j++) {
  13. System.out.print(tablica[i][j]);
  14. }
  15. System.out.println();
  16.  
  17. }
  18.  
  19. }
  20.  
  21. }
  22.  
  23.  
  24. //123
  25. //246
  26. //369
Advertisement
Add Comment
Please, Sign In to add comment