# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
523239 | 2022-02-07T09:05:10 Z | redstonegamer22 | Odd-even (IZhO11_oddeven) | Python 3 | 13 ms | 2828 KB |
import math n = int(input()) m = math.isqrt(2 * n) - 5 while m <= 0 or (m + 1) * (m + 2) // 2 <= n: m = m + 1 # print(m) a = m * (m + 1) // 2 + m * (m - 1) // 2 b = n - m * (m + 1) // 2 ans = a + 2 * b - 1 print(ans)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 13 ms | 2828 KB | Output isn't correct |
2 | Halted | 0 ms | 0 KB | - |