結果

問題 No.88 次はどっちだ
ユーザー GrenacheGrenache
提出日時 2015-09-23 01:16:22
言語 Java21
(openjdk 21)
結果
AC  
実行時間 121 ms / 5,000 ms
コード長 568 bytes
コンパイル時間 3,107 ms
コンパイル使用メモリ 72,876 KB
実行使用メモリ 56,092 KB
最終ジャッジ日時 2023-09-26 14:34:08
合計ジャッジ時間 5,280 ms
ジャッジサーバーID
(参考情報)
judge15 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 117 ms
55,696 KB
testcase_01 AC 119 ms
56,092 KB
testcase_02 AC 118 ms
55,820 KB
testcase_03 AC 117 ms
55,680 KB
testcase_04 AC 116 ms
55,656 KB
testcase_05 AC 119 ms
55,788 KB
testcase_06 AC 119 ms
55,696 KB
testcase_07 AC 117 ms
55,836 KB
testcase_08 AC 121 ms
55,940 KB
testcase_09 AC 117 ms
55,600 KB
testcase_10 AC 115 ms
55,748 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;


public class Main_yukicoder88 {

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        String s = sc.next();
        String[] oy = new String[2];
        oy[0] = s;
        oy[1] = s.equals("oda") ? "yukiko" : "oda";
        
        int cnt = 0;
        for (int i = 0; i < 8; i++) {
        	for (char e : sc.next().toCharArray()) {
        		if (e == 'b' || e == 'w') {
        			cnt++;
        		}
        	}
        }

        System.out.println(oy[cnt % 2]);

        sc.close();
    }
}
0