結果
問題 |
No.292 芸名
|
ユーザー |
![]() |
提出日時 | 2018-01-22 01:28:45 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 488 bytes |
コンパイル時間 | 652 ms |
コンパイル使用メモリ | 68,716 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-12-25 21:59:57 |
合計ジャッジ時間 | 1,208 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 10 |
ソースコード
#include<iostream> #include<string> #include<algorithm> #include<cmath> #include<math.h> #include<iomanip> #include<stdio.h> #include<cstring> using namespace std; int main(){ string s; int t, u; cin >> s >> t >> u; if(t==u){ s.erase(s.begin()+t); cout << s << endl; } else if(t<=u){ s.erase(s.begin()+t); s.erase(s.begin()+(u-1)); cout << s << endl; } else { s.erase(s.begin()+t); s.erase(s.begin()+u); cout << s << endl; } return 0; }