結果
問題 |
No.88 次はどっちだ
|
ユーザー |
![]() |
提出日時 | 2015-01-04 22:08:08 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 1 ms / 5,000 ms |
コード長 | 333 bytes |
コンパイル時間 | 418 ms |
コンパイル使用メモリ | 22,784 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-06-13 02:16:55 |
合計ジャッジ時間 | 984 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 11 |
コンパイルメッセージ
main.cpp: In function ‘int main()’: main.cpp:9:14: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 9 | scanf( "%s", S ); | ~~~~~^~~~~~~~~~~ main.cpp:14:22: warning: ignoring return value of ‘int scanf(const char*, ...)’ declared with attribute ‘warn_unused_result’ [-Wunused-result] 14 | scanf( "%s", B[i] ); | ~~~~~^~~~~~~~~~~~~~
ソースコード
#include<cstdio> #include<cstring> #define rep(i,a) for(int i=0;i<(a);++i) char S[7], B[8][9]; int main() { scanf( "%s", S ); int cnt = 0; rep( i, 8 ) { scanf( "%s", B[i] ); rep( j, 8 ) cnt += B[i][j] != '.'; } if( cnt == 4 || !(cnt&1) ) puts(S); else puts( strcmp(S, "yukiko")?"yukiko":"oda" ); return 0; }