Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package NestedLoops;
- public class Clock {
- public static void main(String[] args) {
- //за всеки един час -> повтаряме: всяка една минута от 0 до 59
- for (int hour = 0; hour <= 23 ; hour++) {
- for (int minute = 0; minute <= 59; minute++) {
- System.out.printf("%d:%02d%n", hour, minute);
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment