11181 | 2024-07-15 18:40:23 | proba | Legnagyobb téglalap | python3 | Wrong answer 0/100 | 165ms | 14848 KiB |
N = input()
sor = [int(i) for i in input().split(' ')]
sor.sort(reverse=True)
h = len(sor)
i, a, b = 0, None, None
while i < h-2:
if sor[i] == sor[i+1] and sor[i+1] == sor[i+2] and sor[i+2] == sor[i+3]:
print(sor[i]**2)
break
elif sor[i] == sor[i+1] and a == None:
a = sor[i]
elif sor[i] == sor[i+1] and b == None:
print(a*sor[i])
break
i += 1
if i == h-2:
print(0)
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 17ms | 3044 KiB | ||||
2 | Accepted | 17ms | 3096 KiB | ||||
3 | Accepted | 17ms | 2952 KiB | ||||
subtask2 | 0/10 | ||||||
4 | Accepted | 17ms | 3044 KiB | ||||
5 | Wrong answer | 18ms | 2968 KiB | ||||
6 | Runtime error | 17ms | 3060 KiB | ||||
7 | Accepted | 17ms | 3044 KiB | ||||
8 | Accepted | 17ms | 2916 KiB | ||||
subtask3 | 0/10 | ||||||
9 | Wrong answer | 18ms | 2972 KiB | ||||
10 | Wrong answer | 17ms | 2984 KiB | ||||
11 | Accepted | 18ms | 3208 KiB | ||||
12 | Wrong answer | 17ms | 3092 KiB | ||||
13 | Accepted | 43ms | 5028 KiB | ||||
14 | Accepted | 46ms | 4924 KiB | ||||
subtask4 | 0/15 | ||||||
15 | Accepted | 17ms | 3064 KiB | ||||
16 | Accepted | 17ms | 3100 KiB | ||||
17 | Accepted | 17ms | 3180 KiB | ||||
18 | Accepted | 17ms | 3056 KiB | ||||
19 | Wrong answer | 18ms | 3080 KiB | ||||
20 | Accepted | 17ms | 3044 KiB | ||||
21 | Accepted | 17ms | 3044 KiB | ||||
22 | Wrong answer | 17ms | 3044 KiB | ||||
23 | Accepted | 17ms | 3044 KiB | ||||
24 | Wrong answer | 17ms | 3044 KiB | ||||
subtask5 | 0/20 | ||||||
25 | Wrong answer | 19ms | 3164 KiB | ||||
26 | Accepted | 20ms | 3640 KiB | ||||
27 | Wrong answer | 21ms | 3620 KiB | ||||
28 | Accepted | 25ms | 3812 KiB | ||||
29 | Accepted | 25ms | 3444 KiB | ||||
30 | Accepted | 21ms | 3516 KiB | ||||
31 | Accepted | 21ms | 3704 KiB | ||||
32 | Wrong answer | 19ms | 3572 KiB | ||||
subtask6 | 0/15 | ||||||
33 | Wrong answer | 17ms | 3044 KiB | ||||
34 | Accepted | 61ms | 14796 KiB | ||||
35 | Accepted | 128ms | 14768 KiB | ||||
36 | Accepted | 128ms | 14692 KiB | ||||
37 | Accepted | 101ms | 14848 KiB | ||||
38 | Accepted | 68ms | 14720 KiB | ||||
39 | Accepted | 54ms | 14752 KiB | ||||
40 | Accepted | 21ms | 4340 KiB | ||||
41 | Wrong answer | 59ms | 14624 KiB | ||||
subtask7 | 0/30 | ||||||
42 | Accepted | 78ms | 14276 KiB | ||||
43 | Accepted | 86ms | 14700 KiB | ||||
44 | Accepted | 165ms | 14832 KiB | ||||
45 | Accepted | 96ms | 14744 KiB | ||||
46 | Wrong answer | 93ms | 14840 KiB | ||||
47 | Accepted | 104ms | 14704 KiB | ||||
48 | Wrong answer | 82ms | 14700 KiB | ||||
49 | Accepted | 160ms | 14824 KiB | ||||
50 | Wrong answer | 82ms | 14812 KiB | ||||
51 | Wrong answer | 83ms | 14520 KiB |