Submission #2690336
Source Code Expand
#!/usr/bin/env python3 import sys def debug(*args): print(*args, file=sys.stderr) def exit(): sys.exit(0) N, Z, W = map(int, input().split()) a = list(map(int, input().split())) if N == 1: print(abs(a[-1]-W)) exit() print(max(abs(a[-2] - a[-1]), abs(a[-1] - W)))
Submission Info
Submission Time | |
---|---|
Task | D - ABS |
User | wktkshn |
Language | PyPy3 (2.4.0) |
Score | 500 |
Code Size | 298 Byte |
Status | AC |
Exec Time | 185 ms |
Memory | 39664 KB |
Judge Result
Set Name | Sample | All | ||||
---|---|---|---|---|---|---|
Score / Max Score | 0 / 0 | 500 / 500 | ||||
Status |
|
|
Set Name | Test Cases |
---|---|
Sample | example_0, example_1, example_2, example_3 |
All | example_0, example_1, example_2, example_3, one_0, one_1, one_2, one_3, one_4, one_5, one_6, one_7, rand_0, rand_1, rand_10, rand_11, rand_12, rand_13, rand_14, rand_15, rand_2, rand_3, rand_4, rand_5, rand_6, rand_7, rand_8, rand_9 |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
example_0 | AC | 176 ms | 38384 KB |
example_1 | AC | 176 ms | 38256 KB |
example_2 | AC | 175 ms | 38256 KB |
example_3 | AC | 171 ms | 38256 KB |
one_0 | AC | 171 ms | 38256 KB |
one_1 | AC | 171 ms | 38256 KB |
one_2 | AC | 169 ms | 38256 KB |
one_3 | AC | 185 ms | 38700 KB |
one_4 | AC | 169 ms | 38256 KB |
one_5 | AC | 171 ms | 38256 KB |
one_6 | AC | 168 ms | 38256 KB |
one_7 | AC | 169 ms | 38256 KB |
rand_0 | AC | 184 ms | 39664 KB |
rand_1 | AC | 170 ms | 38256 KB |
rand_10 | AC | 174 ms | 38640 KB |
rand_11 | AC | 171 ms | 38384 KB |
rand_12 | AC | 172 ms | 38640 KB |
rand_13 | AC | 171 ms | 38640 KB |
rand_14 | AC | 173 ms | 38640 KB |
rand_15 | AC | 170 ms | 38256 KB |
rand_2 | AC | 172 ms | 38640 KB |
rand_3 | AC | 173 ms | 38640 KB |
rand_4 | AC | 173 ms | 38640 KB |
rand_5 | AC | 175 ms | 38640 KB |
rand_6 | AC | 179 ms | 38640 KB |
rand_7 | AC | 172 ms | 38640 KB |
rand_8 | AC | 172 ms | 38640 KB |
rand_9 | AC | 174 ms | 38640 KB |