結果
問題 |
No.3261 yiwiy9 → yiwiY9
|
ユーザー |
![]() |
提出日時 | 2025-09-14 11:48:26 |
言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 443 bytes |
コンパイル時間 | 1,018 ms |
コンパイル使用メモリ | 88,400 KB |
実行使用メモリ | 7,844 KB |
最終ジャッジ日時 | 2025-09-14 11:48:29 |
合計ジャッジ時間 | 2,359 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
other | AC * 7 WA * 22 |
ソースコード
// ,,廿_廿,, #include<iostream> #include<vector> using namespace std; int main(){ int h,w;cin>>h>>w; vector<string>hw(h);for(int i=0;i<h;++i)cin>>hw[i]; string yiwiy[] { "yiwiy9", "9yiwiy", "yiwiY9", "9Yiwiy", }; for(int i=0;i<h;++i){ for(int j=0;j<w-5;++j){ string str=hw[i].substr(j,6); if(str==yiwiy[0])hw[i][j+4]='Y',j+=6; if(str==yiwiy[1])hw[i][j+1]='Y',j+=6; } } for(int i=0;i<h;++i)cout<<hw[i]<<'\n'; }