結果

問題 No.652 E869120 and TimeZone
ユーザー mencotton
提出日時 2018-03-12 14:26:19
言語 C#(csc)
(csc 3.9.0)
結果
WA  
実行時間 -
コード長 582 bytes
コンパイル時間 2,111 ms
コンパイル使用メモリ 103,296 KB
実行使用メモリ 18,048 KB
最終ジャッジ日時 2024-11-07 18:25:33
合計ジャッジ時間 4,221 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 5
other AC * 29 WA * 1
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;

namespace _652
{
    class Program
    {
        static void Main(string[] args)
        {
            string[] s = Console.ReadLine().Split();
            int a = (int)(60 * double.Parse(s[2].Substring(3,s[2].Length - 3))) + 900;
            int time = int.Parse(s[0]) * 60 + int.Parse(s[1]); time += a;
            int hour = time / 60 % 24;
            if (hour < 10) Console.Write(0);
            Console.Write(hour + ":");
            int minute = time % 60;
            if (minute < 10) Console.Write(0);
            Console.WriteLine(minute);
        }
    }
}
0