結果
問題 | No.2021 Not A but B |
ユーザー |
|
提出日時 | 2023-10-29 18:07:09 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
MLE
|
実行時間 | - |
コード長 | 388 bytes |
コンパイル時間 | 1,648 ms |
コンパイル使用メモリ | 172,796 KB |
実行使用メモリ | 814,932 KB |
最終ジャッジ日時 | 2024-09-25 16:50:45 |
合計ジャッジ時間 | 5,324 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 4 MLE * 1 -- * 21 |
ソースコード
#include<bits/stdc++.h>using namespace std;using ll = long long;#define rep(i,m,n) for(int i=m; i<n; ++i)#define repl(i,m,n) for(ll i=m; i<n; ++i)int main(){int N;string S;cin >> N >> S;set<string> st;rep(i, 0, N-1){string T = S;T[i] = 'B';T[i+1] = 'B';st.insert(T);}cout << st.size() << endl;return 0;}