結果

問題 No.296 n度寝
ユーザー ilplrr
提出日時 2018-02-18 19:06:48
言語 C++11(廃止可能性あり)
(gcc 13.3.0)
結果
AC  
実行時間 2 ms / 1,000 ms
コード長 282 bytes
コンパイル時間 396 ms
コンパイル使用メモリ 55,808 KB
実行使用メモリ 5,376 KB
最終ジャッジ日時 2024-07-03 22:50:48
合計ジャッジ時間 1,039 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 16
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <algorithm>
#include <string>
#include <cstdio>
using namespace std;

int main()
{
    int n, h, m, t;
    cin >> n >> h >> m >> t;

    t *= (n - 1);

    h = (h + (m += t) / 60) % 24;
    m %= 60;

    cout << h << endl << m << endl;

    return 0;
}
0