結果

問題 No.296 n度寝
ユーザー ゆうPゆうP
提出日時 2024-03-16 13:57:06
言語 Go
(1.22.1)
結果
WA  
実行時間 -
コード長 371 bytes
コンパイル時間 15,333 ms
コンパイル使用メモリ 216,220 KB
実行使用メモリ 6,676 KB
最終ジャッジ日時 2024-03-16 13:57:23
合計ジャッジ時間 16,663 ms
ジャッジサーバーID
(参考情報)
judge14 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 WA -
testcase_02 AC 2 ms
6,676 KB
testcase_03 AC 1 ms
6,676 KB
testcase_04 AC 1 ms
6,676 KB
testcase_05 AC 2 ms
6,676 KB
testcase_06 AC 1 ms
6,676 KB
testcase_07 WA -
testcase_08 AC 1 ms
6,676 KB
testcase_09 AC 2 ms
6,676 KB
testcase_10 AC 1 ms
6,676 KB
testcase_11 AC 1 ms
6,676 KB
testcase_12 AC 1 ms
6,676 KB
testcase_13 AC 1 ms
6,676 KB
testcase_14 AC 1 ms
6,676 KB
testcase_15 AC 1 ms
6,676 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

// No.296 n度寝
package main

import (
	"fmt"
	"time"
)

func main() {
	var n, h, m, t int // N度寝、アラームH、M、アラーム間隔

	fmt.Scan(&n, &h, &m, &t)
	start := time.Date(1, 1, 1, h, m, 0, 0, time.Local)
	fmt.Println(start.Add(time.Minute * time.Duration((n-1)*t)).Hour())
	fmt.Println(start.Add(time.Minute * time.Duration((n-1)*t)).Minute())
}
0