結果

問題 No.63 ポッキーゲーム
ユーザー zmirezzmirez
提出日時 2018-05-11 19:34:17
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 1,174 ms / 5,000 ms
コード長 435 bytes
コンパイル時間 2,286 ms
コンパイル使用メモリ 105,484 KB
実行使用メモリ 22,856 KB
最終ジャッジ日時 2023-09-10 12:38:26
合計ジャッジ時間 8,121 ms
ジャッジサーバーID
(参考情報)
judge13 / judge12
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 60 ms
20,840 KB
testcase_01 AC 60 ms
20,804 KB
testcase_02 AC 60 ms
20,860 KB
testcase_03 AC 61 ms
20,772 KB
testcase_04 AC 58 ms
20,808 KB
testcase_05 AC 57 ms
18,656 KB
testcase_06 AC 58 ms
22,848 KB
testcase_07 AC 60 ms
20,744 KB
testcase_08 AC 59 ms
22,856 KB
testcase_09 AC 61 ms
20,924 KB
testcase_10 AC 70 ms
22,788 KB
testcase_11 AC 1,172 ms
18,796 KB
testcase_12 AC 80 ms
20,804 KB
testcase_13 AC 1,174 ms
20,828 KB
testcase_14 AC 80 ms
20,856 KB
testcase_15 AC 82 ms
20,816 KB
testcase_16 AC 61 ms
20,732 KB
testcase_17 AC 1,104 ms
22,840 KB
testcase_18 AC 59 ms
20,780 KB
testcase_19 AC 209 ms
22,792 KB
testcase_20 AC 75 ms
22,824 KB
testcase_21 AC 106 ms
18,756 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
class Program{
    static void Main(string []args){
        string[]t=(Console.ReadLine()).Split(' ');
        long L=long.Parse(t[0]);
        int K=int.Parse(t[1]);
        Console.WriteLine(Pockey(L,K));

    }
    static int Pockey (long L,int K){
        int count=0;
        while(L>0){
            L=L-2*K;
            if(L<=0)break;
            count++;
        }
        return count*K;
    }
}
0