Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <bits/stdc++.h>
- #include <ext/pb_ds/assoc_container.hpp>
- #include <ext/pb_ds/detail/standard_policies.hpp>
- using namespace std;
- using namespace __gnu_pbds;
- template<typename T>
- using indexed_set [[maybe_unused]] = tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>;
- #define ll long long
- #define pb push_back
- #define SZ(v) ((int)((v).size()))
- #define UNIQUE(v) sort(all(v));v.erase(unique(all(v)),v.end());
- const int N = 70;
- int a[N][N];
- void run () {
- int n;
- cin >> n;
- int pos = 0;
- for (int i = 1; i <= n; ++i) {
- for (int j = 1; j <= n; ++j) {
- cin >> a[i][j];
- if (a[i][j] == n - 1)
- pos = j;
- }
- }
- for (int i = 1; i <= n; ++i) {
- if (i != pos) {
- cout << a[pos][i] << " ";
- } else {
- cout << n << " ";
- }
- }
- }
- int main () {
- ios_base::sync_with_stdio(false);
- cin.tie(nullptr);
- cout.tie(nullptr);
- // freopen("/home/hamoudi/clion/hello.in", "rt", stdin);
- int tt;
- tt = 1;
- // cin >> tt;
- while (tt--)
- run();
- }
- /*
- */
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement