Submission #226176

#TimeUsernameProblemLanguageResultExecution timeMemory
226176osaaateiasavtnlProsjecni (COCI16_prosjecni)C++14
24 / 120
5 ms384 KiB
#include<bits/stdc++.h> using namespace std; #define int long long #define ii pair <int, int> #define app push_back #define all(a) a.begin(), a.end() #define bp __builtin_popcount #define ll long long #define mp make_pair #define f first #define s second #define Time (double)clock()/CLOCKS_PER_SEC signed main() { #ifdef HOME freopen("input.txt", "r", stdin); #else #define endl '\n' ios_base::sync_with_stdio(0); cin.tie(0); #endif int n; cin >> n; if (n == 2) exit(1); if (n % 2 == 0) { cout << -1 << endl; } else { int x = 0; for (int i = 0; i < n; ++i) { for (int j = 0; j < n; ++j) { ++x; cout << x << ' '; } cout << endl; } } }
#Verdict Execution timeMemoryGrader output
Fetching results...