Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
111221 殷佳雨萱 字符串中最大的数字II C++ Accepted 1 MS 272 KB 226 2025-03-01 11:02:18

Tests(10/10):


Code:

#include<bits/stdc++.h> using namespace std; int main() { string s1; cin>>s1; int len=s1.size(); int asy=s1[0]; char a='0'; for(int i=0;i<len;i++){ if(s1[i]>a){ a=s1[i]; } } cout<<a; return 0; }