Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
3775 邓小龙 如何得到"hello" C++ Accepted 0 MS 252 KB 352 2024-07-03 12:08:26

Tests(20/20):


Code:

# include<iostream> # include<cstring> using namespace std; int main(){ char f[6]="hello", a[1501]; int n = 0, l = 0; cin>>a; l = strlen(a); for(int i = 0; i < l; i++){ if(a[i]==f[n]){ n++; } } if(n>=5){ cout<<"YES"; }else{ cout<<"NO"; } return 0; }