We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e1d0198 commit a836a2fCopy full SHA for a836a2f
게임 이론/25335.cpp
@@ -0,0 +1,40 @@
1
+#include <iostream>
2
+using namespace std;
3
+
4
+int r, g, b;
5
+int N, M;
6
7
+void func() {
8
+ r += (g >> 1);
9
+ b += (g >> 1);
10
+ if (g & 1) r++;
11
12
+ if (r > b) cout << "jhnah917\n";
13
+ else cout << "jhnan917\n";
14
+}
15
16
+void input() {
17
+ int x, y;
18
+ cin >> N >> M;
19
+ while (N--) {
20
+ cin >> x >> y;
21
+ }
22
23
+ char c;
24
+ while (M--) {
25
+ cin >> x >> y >> c;
26
+ if (c == 'R') r++;
27
+ else if (c == 'G') g++;
28
+ else b++;
29
30
31
32
+int main() {
33
+ cin.tie(NULL); cout.tie(NULL);
34
+ ios::sync_with_stdio(false);
35
36
+ input();
37
+ func();
38
39
+ return 0;
40
0 commit comments