Submission #28387017
Source Code Expand
n = int(input())
points = [list(map(int, input().split())) for i in range(n)]
ans2 = 0
for i in range(n):
for j in range(n):
x_1, y_1 = points[i]
x_2, y_2 = points[j]
length2 = (x_1 - x_2)**2 + (y_1 - y_2)**2
ans2 = max(ans2, length2)
print(ans2 ** (0.5))
Submission Info
| Submission Time | |
|---|---|
| Task | B - Longest Segment |
| User | ginji |
| Language | Python (3.8.2) |
| Score | 200 |
| Code Size | 302 Byte |
| Status | AC |
| Exec Time | 34 ms |
| Memory | 9372 KiB |
Judge Result
| Set Name | Sample | All | ||||
|---|---|---|---|---|---|---|
| Score / Max Score | 0 / 0 | 200 / 200 | ||||
| Status |
|
|
| Set Name | Test Cases |
|---|---|
| Sample | example0.txt, example1.txt |
| All | 000.txt, 001.txt, 002.txt, 003.txt, 004.txt, 005.txt, 006.txt, 007.txt, 008.txt, 009.txt, 010.txt, example0.txt, example1.txt |
| Case Name | Status | Exec Time | Memory |
|---|---|---|---|
| 000.txt | AC | 29 ms | 8944 KiB |
| 001.txt | AC | 32 ms | 9148 KiB |
| 002.txt | AC | 23 ms | 9372 KiB |
| 003.txt | AC | 25 ms | 9140 KiB |
| 004.txt | AC | 26 ms | 9152 KiB |
| 005.txt | AC | 26 ms | 9140 KiB |
| 006.txt | AC | 24 ms | 9152 KiB |
| 007.txt | AC | 33 ms | 9152 KiB |
| 008.txt | AC | 17 ms | 9244 KiB |
| 009.txt | AC | 34 ms | 9320 KiB |
| 010.txt | AC | 32 ms | 9320 KiB |
| example0.txt | AC | 18 ms | 9248 KiB |
| example1.txt | AC | 21 ms | 9244 KiB |