1 条题解
-
0
using namespace std; int main() { string s; cin>>s; int len = s.size(); if(len<4) { cout<<s; return 0; } string s1 = s.substr(len-2); string s2 = s.substr(len-2); string t= s; if(s1=="ly"||s1=="er") { t = s.substr(0,len-2); } else if (s2 =="ing") { t=s.substr(0,len-3); } cout<<t; return 0; } //https://www.bilibili.com/video/BV1U84y1w7wn?spm_id_from=333.788.player.switch&vd_source=42c02d8f2977de812d87f471f8153d89
信息
- ID
- 1306
- 时间
- 1000ms
- 内存
- 128MiB
- 难度
- 4
- 标签
- (无)
- 递交数
- 44
- 已通过
- 20
- 上传者