-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path20499.cpp
More file actions
42 lines (37 loc) · 704 Bytes
/
20499.cpp
File metadata and controls
42 lines (37 loc) · 704 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
// 20499. Darius님 한타 안 함?
// 2021.10.11
// 문자열
#include<iostream>
#include<vector>
#include<string>
#include<sstream>
using namespace std;
vector<string> split(string input, char delimiter)
{
vector<string> answer;
stringstream ss(input);
string temp;
while (getline(ss, temp, delimiter))
{
answer.push_back(temp);
}
return answer;
}
int main()
{
string s;
cin >> s;
vector<string> result = split(s, '/');
int k = stoi(result[0]);
int d = stoi(result[1]);
int a = stoi(result[2]);
if (k + a < d || d == 0)
{
cout << "hasu" << endl;
}
else
{
cout << "gosu" << endl;
}
return 0;
}