Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
111217 | 王煜鑫 | 字符串中最大的数字 | C++ | Wrong Answer | 1 MS | 280 KB | 223 | 2025-03-01 11:00:55 |
#include<iostream> using namespace std; int main(){ string s; char a='0'; int len; cin>>s; len=s.size(); for(int i=1;i<=len;i++){ if(s[i]>a){ a=s[i]; } } cout<<a<<endl; }
------Input------
1
------Answer-----
1
------Your output-----
0