結果

問題 No.88 次はどっちだ
ユーザー papipenpapipen
提出日時 2017-04-11 21:04:53
言語 Java21
(openjdk 21)
結果
AC  
実行時間 125 ms / 5,000 ms
コード長 439 bytes
コンパイル時間 2,040 ms
コンパイル使用メモリ 72,236 KB
実行使用メモリ 55,984 KB
最終ジャッジ日時 2023-09-25 11:17:18
合計ジャッジ時間 4,171 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 124 ms
55,484 KB
testcase_01 AC 122 ms
55,780 KB
testcase_02 AC 123 ms
55,628 KB
testcase_03 AC 123 ms
55,304 KB
testcase_04 AC 120 ms
55,760 KB
testcase_05 AC 125 ms
55,788 KB
testcase_06 AC 123 ms
55,904 KB
testcase_07 AC 123 ms
55,984 KB
testcase_08 AC 123 ms
55,672 KB
testcase_09 AC 123 ms
55,672 KB
testcase_10 AC 124 ms
55,480 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

import java.util.Scanner;
class N088{
	public static void main(String args[]){
		Scanner s = new Scanner(System.in);
		String a = s.next();
		String b = a.equals("oda") ? "yukiko" : "oda";
		int count = 0;
		for(int i = 0; i < 8; i++){
			String c = s.next();
			for(int j = 0; j < 8; j++){
				if(c.charAt(j) != '.'){
					count++;
				}
			}
		}
		if(count % 2 == 0){
			System.out.println(a);
		}else{
			System.out.println(b);
		}
	}
}
0