Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
102290 叶城俊 统计数字字符个数 C++ Wrong Answer 1 MS 280 KB 712 2024-12-21 14:46:59

Tests(0/10):


Code:

#include<iostream> using namespace std; int main (){ /**char a[1001]; bool falg=true; int b=0; cin>>a; while(a[b]!='\0') b++; for(int i=0;i<b/2;i++){ if(a[i]!=a[b-1-i]){ falg=false; } } if(falg){ cout<<"Yes"; } else cout<<"No"; char a,b,str[201],c=0; a=cin.get(); cin.get(); b=cin.get(); cin>>str; while(str[c]!='\0'){ if(str[c]==a){ str[c]=b; } c++; } cout<<str;**/ char a[226]; int c=0,b=0; cin>>a; while(a[c]!='\0'){ c++; } for(int i=0;i<c;i++){ if(a[i]>='0' && a[i]<='9'){ b++; } } cout<<b; return 0; }


Run Info:

------Input------
I have seen 3 persons over there.
------Answer-----
1
------Your output-----
0