제출 #374316

#제출 시각아이디문제언어결과실행 시간메모리
374316NONAMEEuklid (COCI20_euklid)C++17
컴파일 에러
0 ms0 KiB
#include <bits/stdc++.h>
using namespace std;
mt19937 rnd(chrono::steady_clock::now().time_since_epoch().count());

void solve() {
    cin >> g >> h;
    if (g == h) {
        cout << g << " " << g << "\n";
    } else {
        assert(0);
    }
}

int main() {
    ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);

    int t;
    cin >> t;
    while (t--) {
        solve();
    }

    return 0;
}

컴파일 시 표준 에러 (stderr) 메시지

euklid.cpp: In function 'void solve()':
euklid.cpp:6:12: error: 'g' was not declared in this scope
    6 |     cin >> g >> h;
      |            ^
euklid.cpp:6:17: error: 'h' was not declared in this scope
    6 |     cin >> g >> h;
      |                 ^