Advertisement
deyanivanov966

NESTED LOOPS - LAB 01. Clock

Apr 5th, 2021
208
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.34 KB | None | 0 0
  1. import java.util.Scanner;
  2. public class clock {
  3.     public static void main(String[] args) {
  4.         Scanner scanner = new Scanner(System.in);
  5.         for (int hours=0; hours<=23; hours++){
  6.             for (int minutes=0; minutes<=59; minutes++){
  7.                 System.out.printf("%d:%d%n", hours, minutes);
  8.             }
  9.         }
  10.     }
  11. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement