結果
問題 |
No.2773 Wake up Record 1
|
ユーザー |
|
提出日時 | 2024-06-07 22:12:54 |
言語 | C++23 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 363 bytes |
コンパイル時間 | 6,452 ms |
コンパイル使用メモリ | 274,752 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-26 08:19:12 |
合計ジャッジ時間 | 4,231 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 WA * 2 |
other | AC * 9 WA * 13 |
ソースコード
#include<bits/stdc++.h> using namespace std; int main(){ int s; cin >> s; string str; cin >> str; vector<int> ans; for(int i = 2; i < str.length(); i++){ if(str[i] != str[i - 1] && str[i] == 'o' && str[i - 1] == 'x'){ ans.push_back(i + 1); } } cout << ans.size() << endl; for(int i = 0; i < ans.size(); i++){ cout << ans[i] << " "; } return 0; }