結果

問題 No.525 二度寝の季節
ユーザー TwinkleStar74TwinkleStar74
提出日時 2017-10-17 23:01:50
言語 Java21
(openjdk 21)
結果
AC  
実行時間 92 ms / 1,000 ms
コード長 734 bytes
コンパイル時間 3,515 ms
コンパイル使用メモリ 74,264 KB
実行使用メモリ 39,824 KB
最終ジャッジ日時 2024-04-29 06:28:54
合計ジャッジ時間 7,673 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 83 ms
39,800 KB
testcase_01 AC 77 ms
37,760 KB
testcase_02 AC 80 ms
39,788 KB
testcase_03 AC 80 ms
38,092 KB
testcase_04 AC 81 ms
39,820 KB
testcase_05 AC 81 ms
38,136 KB
testcase_06 AC 84 ms
38,028 KB
testcase_07 AC 80 ms
38,108 KB
testcase_08 AC 81 ms
39,736 KB
testcase_09 AC 80 ms
38,156 KB
testcase_10 AC 85 ms
38,116 KB
testcase_11 AC 82 ms
38,124 KB
testcase_12 AC 78 ms
37,924 KB
testcase_13 AC 88 ms
39,688 KB
testcase_14 AC 82 ms
39,700 KB
testcase_15 AC 79 ms
39,692 KB
testcase_16 AC 79 ms
37,936 KB
testcase_17 AC 80 ms
37,836 KB
testcase_18 AC 92 ms
38,172 KB
testcase_19 AC 80 ms
37,924 KB
testcase_20 AC 88 ms
39,824 KB
testcase_21 AC 79 ms
39,692 KB
testcase_22 AC 80 ms
38,256 KB
testcase_23 AC 79 ms
37,768 KB
testcase_24 AC 78 ms
38,288 KB
testcase_25 AC 79 ms
37,868 KB
testcase_26 AC 77 ms
38,172 KB
testcase_27 AC 80 ms
38,080 KB
testcase_28 AC 88 ms
37,832 KB
testcase_29 AC 77 ms
37,868 KB
testcase_30 AC 86 ms
39,244 KB
testcase_31 AC 81 ms
39,496 KB
testcase_32 AC 81 ms
38,100 KB
testcase_33 AC 82 ms
39,588 KB
testcase_34 AC 82 ms
39,672 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.io.*;

public class No525{
    public static void main(String[] args) throws IOException{
        String[] time = new BufferedReader(new InputStreamReader(System.in)).readLine().split(":");
        int hour = Integer.parseInt(time[0]);
        int minute = Integer.parseInt(time[1]);
        secondGetupTime(hour, minute);
    }
    
    public static void secondGetupTime(int a, int b){
        b += 5;
        if (b/60 != 0) a++;
        b %= 60;
        a %= 24;
        if(a< 10 && b < 10)  System.out.println("0" + a + ":" + "0" + b); 
        else if(a < 10)  System.out.println("0"+ a + ":" + b);
        else if(b < 10)  System.out.println(a + ":" + "0" + b);
        else  System.out.println(a + ":" + b);
    }
}
0