Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
81778 李雨昊 如何得到"hello" C++ Accepted 1 MS 292 KB 289 2024-07-12 15:31:42

Tests(20/20):


Code:

#include<cstring> #include<iostream> using namespace std; int main() { char a[11501],b[11501]={'h','e','l','l','o'}; cin >> a; int n=0; for (int i = 0; a[i] != '\0'; i++) { if (a[i] == b[n]) { n++; } } if(n == 5){ cout<<"YES"; }else{ cout<<"NO"; } }