Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
111328 | 殷佳雨萱 | 如何得到"hello" | C++ | Accepted | 1 MS | 276 KB | 271 | 2025-03-01 11:52:56 |
#include<bits/stdc++.h> using namespace std; int main() { string s1,s2="hello"; cin>>s1; int len=s1.size(); int i=0; for(int j=0;j<len;j++){ if(s1[j]==s2[i]){ i++; } } if(i==5){ cout<<"YES"; return 0; } cout<<"NO"; return 0; }