結果

問題 No.296 n度寝
ユーザー yu_017yu_017
提出日時 2019-02-03 09:55:17
言語 Java21
(openjdk 21)
結果
AC  
実行時間 125 ms / 1,000 ms
コード長 373 bytes
コンパイル時間 4,463 ms
コンパイル使用メモリ 72,220 KB
実行使用メモリ 56,292 KB
最終ジャッジ日時 2023-08-22 02:01:28
合計ジャッジ時間 7,741 ms
ジャッジサーバーID
(参考情報)
judge14 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 124 ms
55,712 KB
testcase_01 AC 123 ms
55,752 KB
testcase_02 AC 124 ms
55,720 KB
testcase_03 AC 124 ms
55,876 KB
testcase_04 AC 122 ms
56,048 KB
testcase_05 AC 124 ms
56,048 KB
testcase_06 AC 123 ms
55,968 KB
testcase_07 AC 125 ms
56,148 KB
testcase_08 AC 122 ms
56,292 KB
testcase_09 AC 122 ms
56,196 KB
testcase_10 AC 120 ms
55,972 KB
testcase_11 AC 122 ms
55,900 KB
testcase_12 AC 123 ms
56,000 KB
testcase_13 AC 123 ms
55,768 KB
testcase_14 AC 122 ms
56,192 KB
testcase_15 AC 122 ms
55,992 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;

public class A000296 {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt();
		int h = sc.nextInt();
		int m = sc.nextInt();
		int t = sc.nextInt();
		sc.close();
		int rh = h;
		int rm = m;
		rh+=((n-1)*t+m)/60;
		rm =((n-1)*t+m)%60;
		System.out.println(rh%24);
		System.out.println(rm);
	}
}
0