-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathA_Chat_room.cpp
More file actions
47 lines (40 loc) · 913 Bytes
/
Copy pathA_Chat_room.cpp
File metadata and controls
47 lines (40 loc) · 913 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#include <bits/stdc++.h>
#define push \
ios_base::sync_with_stdio(0); \
cin.tie(NULL);
#define sac sort(v.begin(), v.end())
#define sdc sort(v.begin(), v.end(), greater<int>())
#define f1 bool flag = true
#define f0 bool flag = false
#define c0 int count = 0
#define c1 int count = 1
#define s0 int sum = 0
#define ll long long
#define yes cout << "YES" << endl
#define no cout << "NO" << endl
#define minus cout << -1 << endl
#define cnt cout << count << endl
#define sm cout << sum << endl
using namespace std;
int main()
{
push;
string s;
cin >> s;
string s2 = "hello";
f0;
for (int i = 0, j = 0; i < s.size() && j < s2.size(); i++)
{
if (s2[j] == s[i])
{
j++;
if (j == s2.size())
{
flag = true;
}
}
}
if (flag) yes;
else no;
return 0;
}