Advertisement
Guest User

Untitled

a guest
Nov 18th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.92 KB | None | 0 0
  1.  
  2. Scanner sc = new Scanner (System.in);
  3. int smer = 0; // 0 (sever), 1(vzhod), 2(jug), 3(zahod)
  4. int stVrstic = sc.nextInt();
  5. int stStolpcev = sc.nextInt();
  6.  
  7. int [][] lab = new int [stVrstic][stStolpcev];
  8.  
  9. for (int i = 0; i < stVrstic; i++) {
  10. for (int j = 0; j < stStolpcev; j++) {
  11. lab[i][j] = sc.nextInt();
  12. }
  13. }
  14.  
  15. int stFunkcij = sc.nextInt();
  16.  
  17. String [][] funkcije;
  18.  
  19. funkcije = new String [stFunkcij][];
  20.  
  21. System.out.println("stfunkc " +stFunkcij);
  22.  
  23. for (int i = 0; i < stFunkcij; i++) {
  24. int dolzinaFunkcije = sc.nextInt();
  25.  
  26. System.out.println("dolzinafunkcije " +dolzinaFunkcije);
  27.  
  28. funkcije [i] = new String [dolzinaFunkcije];
  29.  
  30. for (int j = 0; j < dolzinaFunkcije; j++) {
  31.  
  32. funkcije[i][j] = sc.nextLine();
  33. System.out.println("funkcija " + i + " ukaz "+ funkcije[i][j] );
  34. }
  35. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement