結果
問題 | No.88 次はどっちだ |
ユーザー |
![]() |
提出日時 | 2015-04-21 00:06:17 |
言語 | C#(csc) (csc 3.9.0) |
結果 |
AC
|
実行時間 | 22 ms / 5,000 ms |
コード長 | 1,007 bytes |
コンパイル時間 | 788 ms |
コンパイル使用メモリ | 103,936 KB |
実行使用メモリ | 17,408 KB |
最終ジャッジ日時 | 2024-07-04 18:57:05 |
合計ジャッジ時間 | 1,448 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 11 |
コンパイルメッセージ
Microsoft (R) Visual C# Compiler version 3.9.0-6.21124.20 (db94f4cc) Copyright (C) Microsoft Corporation. All rights reserved.
ソースコード
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;namespace ForYukicoder{class Program{static void Main(string[] args){string S = Console.ReadLine();string[] B = new string[8];for (int i = 0; i < 8; i++){B[i] = Console.ReadLine();}//-----------------int stone = 0;foreach (var row in B){foreach (var column in row){if (column == 'w' || column == 'b') stone++;}}string str;if (stone % 2 == 0){//黒の順番str = S;}else{//白の順番str = (S == "oda") ? "yukiko" : "oda";}Console.WriteLine(str);}}}