結果
| 問題 | No.82 市松模様 |
| コンテスト | |
| ユーザー |
eri
|
| 提出日時 | 2015-07-02 09:36:40 |
| 言語 | C++11 (gcc 15.3.0 + boost 1.92.0) |
| 結果 |
AC
不安定
|
| 実行時間 | 1 ms / 5,000 ms |
| + 952µs | |
| コード長 | 261 bytes |
| 記録 | |
| コンパイル時間 | 376 ms |
| コンパイル使用メモリ | 75,816 KB |
| 実行使用メモリ | 9,844 KB |
| 最終ジャッジ日時 | 2026-11-20 20:06:42 |
| 合計ジャッジ時間 | 1,965 ms |
|
ジャッジサーバーID (参考情報) |
judge1_0 / judge4_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 8 |
ソースコード
#include<iostream>
using namespace std;
int main(){
int w, h; char c;
cin >> w >> h >> c;
int q = ((c == 'B') ? 1 : 0);
for (int y = 0; y < h; y++){
for (int x = 0; x < w; x++){
cout << ((q + y + x) % 2 ? 'B' : 'W');
}
cout << endl;
}
return 0;
}
eri