結果

問題 No.296 n度寝
ユーザー swdamdr
提出日時 2017-02-24 11:07:52
言語 C#(csc)
(csc 3.9.0)
結果
WA  
実行時間 -
コード長 543 bytes
コンパイル時間 1,730 ms
コンパイル使用メモリ 103,680 KB
実行使用メモリ 18,688 KB
最終ジャッジ日時 2025-01-02 21:58:13
合計ジャッジ時間 2,369 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 11 WA * 5
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
using System.Linq;
using System.Collections.Generic;

class Program
{
    static void Main(string[] args)
    {
        string[] su = Console.ReadLine().Split();
        int cnt = int.Parse(su[0]) - 1;
        int h = int.Parse(su[1]);
        int m = int.Parse(su[2]);
        int time = int.Parse(su[3]);

        m += time * cnt;
        h += m / 60;
        m = m % 60;

        if (h >= 24)
        {
            h -= 24;
        }
        Console.WriteLine(h);
        Console.WriteLine(m);

        Console.Read();
    }
}
0