Submission #338375

#TimeUsernameProblemLanguageResultExecution timeMemory
338375boykutChessboard (IZhO18_chessboard)C++14
0 / 100
1 ms364 KiB
#include <bits/stdc++.h> using namespace std; signed main() { ios::sync_with_stdio(0); cin.tie(0); int n, k; cin >> n >> k; if (k == 0) { int ans = -1; for (int i = 2; i <= n; i++) { if (n % i == 0) { int m = n / i; int res = ((n*n) / (m*m)) / 2 * (m *m); if (ans == -1 || ans < res) ans = res; } } cout << ans << '\n'; } return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...