#include <bits/stdc++.h>

using namespace std;
#define int int64_t
const int mod = 1e9 + 7;
void solve() {
    int n, m, number;
    cin >> n >> m >> number;
    vector<pair<int,int> > edge(m);
    vector<vector<int> > a(n + 1);
    for (int i = 0; i < m; i++) {
        cin >> edge[i].first >> edge[i].second;
        a[edge[i].first].push_back(edge[i].second);
    }
    cout << 0 << " " << 1;
}

int32_t main() {
    ios_base::sync_with_stdio(false);
    cin.tie(nullptr);
    solve();
}






