| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 62570 | 张江鹏 | 删除数字字符 | C++ | Wrong Answer | 1 MS | 272 KB | 562 | 2023-12-24 12:53:20 |
#include<iostream> #include<cstring> using namespace std; int main() { char a[1001]; int dx = 0,xx = 0,sz = 0,qt = 0; int l, i; //输入字符串 cin.getline(a,1001); l = strlen(a); for(i = 0; i < l; i++) { if(a[i] >='A' && a[i] <='Z') { dx++; } else if(a[i] >='a' && a[i] <='z') { xx++; } else if(a[i] >='0' && a[i] <='9') { sz++; } else { qt++; } } cout << dx <<" " << xx <<" "<< sz<<" " << qt; return 0; }
------Input------
vvvv23kjhg4lllk89766gff
------Answer-----
vvvvkjhglllkgff
------Your output-----
0 15 8 0