結果

問題 No.486 3 Straight Win(3連勝)
ユーザー yukicoderyukicoder
提出日時 2017-02-25 00:57:34
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 49 ms / 2,000 ms
コード長 403 bytes
コンパイル時間 1,991 ms
コンパイル使用メモリ 101,932 KB
実行使用メモリ 22,576 KB
最終ジャッジ日時 2023-09-08 10:46:18
合計ジャッジ時間 4,589 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 48 ms
22,576 KB
testcase_01 AC 48 ms
22,540 KB
testcase_02 AC 48 ms
22,492 KB
testcase_03 AC 48 ms
20,456 KB
testcase_04 AC 47 ms
20,564 KB
testcase_05 AC 48 ms
20,492 KB
testcase_06 AC 49 ms
20,524 KB
testcase_07 AC 48 ms
20,520 KB
testcase_08 AC 49 ms
20,392 KB
testcase_09 AC 48 ms
18,440 KB
testcase_10 AC 48 ms
20,580 KB
testcase_11 AC 48 ms
22,564 KB
testcase_12 AC 48 ms
20,452 KB
testcase_13 AC 48 ms
18,360 KB
testcase_14 AC 49 ms
20,560 KB
testcase_15 AC 47 ms
20,400 KB
testcase_16 AC 48 ms
22,432 KB
testcase_17 AC 47 ms
20,520 KB
testcase_18 AC 47 ms
20,464 KB
testcase_19 AC 49 ms
20,460 KB
testcase_20 AC 48 ms
20,468 KB
testcase_21 AC 49 ms
18,340 KB
testcase_22 AC 48 ms
22,548 KB
testcase_23 AC 48 ms
22,520 KB
testcase_24 AC 48 ms
20,524 KB
testcase_25 AC 48 ms
20,532 KB
testcase_26 AC 49 ms
20,532 KB
testcase_27 AC 48 ms
20,532 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc)
Copyright (C) Microsoft Corporation. All rights reserved.

ソースコード

diff #

using System;
public class Program
{
    static void Main()
    {
        string s = Console.ReadLine();

        string ans = "NA";
        for (int i = 0; i < s.Length - 2; i++)
        {
            if (s[i] == s[i + 1] && s[i + 1] == s[i + 2])
            {
                ans = (s[i] == 'O') ? "East" : "West";
                break;
            }
        }
        Console.WriteLine(ans);
    }
}
0