結果

問題 No.1941 CHECKER×CHECKER(1)
ユーザー bluemeganebluemegane
提出日時 2022-05-20 21:49:47
言語 C#(csc)
(csc 3.9.0)
結果
AC  
実行時間 23 ms / 2,000 ms
コード長 751 bytes
コンパイル時間 4,683 ms
コンパイル使用メモリ 106,516 KB
実行使用メモリ 23,500 KB
最終ジャッジ日時 2023-10-20 12:21:40
合計ジャッジ時間 4,121 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 22 ms
23,500 KB
testcase_01 AC 23 ms
23,500 KB
testcase_02 AC 22 ms
23,500 KB
testcase_03 AC 22 ms
23,500 KB
testcase_04 AC 22 ms
23,500 KB
testcase_05 AC 22 ms
23,500 KB
testcase_06 AC 22 ms
23,500 KB
testcase_07 AC 23 ms
23,500 KB
testcase_08 AC 22 ms
23,500 KB
testcase_09 AC 22 ms
23,500 KB
testcase_10 AC 22 ms
23,500 KB
testcase_11 AC 23 ms
23,500 KB
testcase_12 AC 22 ms
23,500 KB
testcase_13 AC 22 ms
23,500 KB
testcase_14 AC 23 ms
23,500 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 Hello
{
    static void Main()
    {
        var s = new string[3];
        for (int i = 0; i < 3; i++) s[i] = Console.ReadLine().Trim();
        getAns(s);
    }
    static void getAns(string[] s)
    {
        Console.WriteLine((check1(s) | check2(s)) ? "Yes" : "No");
    }
    static bool check2(string[] s)
    {
        var t = new string[] { ".#.", "#.#", ".#." };
        for (int i = 0; i < 3; i++)
        {
            if (s[i] != t[i]) return false;
        }
        return true;
    }
    static bool check1(string[] s)
    {
        var t = new string[] { "#.#", ".#.", "#.#" };
        for (int i = 0; i < 3; i++)
        {
            if (s[i] != t[i]) return false;
        }
        return true;
    }
}
0