結果

問題 No.296 n度寝
ユーザー spacenautspacenaut
提出日時 2016-05-22 15:53:23
言語 Java21
(openjdk 21)
結果
WA  
実行時間 -
コード長 373 bytes
コンパイル時間 2,064 ms
コンパイル使用メモリ 76,916 KB
実行使用メモリ 41,492 KB
最終ジャッジ日時 2024-04-16 06:47:57
合計ジャッジ時間 5,313 ms
ジャッジサーバーID
(参考情報)
judge4 / judge1
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 WA -
testcase_03 AC 133 ms
41,244 KB
testcase_04 AC 131 ms
40,944 KB
testcase_05 AC 131 ms
40,944 KB
testcase_06 AC 127 ms
41,232 KB
testcase_07 WA -
testcase_08 WA -
testcase_09 WA -
testcase_10 AC 134 ms
41,312 KB
testcase_11 AC 132 ms
41,380 KB
testcase_12 WA -
testcase_13 AC 139 ms
40,980 KB
testcase_14 AC 147 ms
41,296 KB
testcase_15 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.*;

class No0296{
	public static void main(String[] args){
		Scanner sc = new Scanner(System.in);
		int n = sc.nextInt() - 1;
		int h = sc.nextInt();
		int m = sc.nextInt();
		int t = sc.nextInt();

		for(int i = 0; i < n; i++){
			m += t;
		}
		if(m / 60 > 0){
			h = h + (m / 60);
			m = m % 60;
		}
		System.out.println(h);
		System.out.println(m);
	}
}
0