11178 | 2024-07-15 16:29:52 | proba | Legnagyobb téglalap | python3 | Wrong answer 0/100 | 1.098s | 14848 KiB |
N = int(input())
sor = [int(i) for i in input().split(' ')]
sor.sort(reverse=True)
print(sor)
i = 0
a, b = 0, 0
while i < len(sor):
if sor.count(sor[i]) > 3:
print(sor[i]**2)
break
elif sor.count(sor[i]) > 1:
if a == 0:
a = sor[i]
elif b == 0:
b = sor[i]
break
while i < len(sor) and sor[i] == a:
i += 1
else:
i += 1
if a*b != 0:
print(a*b)
else:
print(0)
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Wrong answer | 17ms | 2964 KiB | ||||
2 | Wrong answer | 17ms | 3228 KiB | ||||
3 | Wrong answer | 18ms | 2968 KiB | ||||
subtask2 | 0/10 | ||||||
4 | Wrong answer | 18ms | 3108 KiB | ||||
5 | Wrong answer | 17ms | 3056 KiB | ||||
6 | Wrong answer | 17ms | 3180 KiB | ||||
7 | Wrong answer | 17ms | 3072 KiB | ||||
8 | Wrong answer | 17ms | 3064 KiB | ||||
subtask3 | 0/10 | ||||||
9 | Wrong answer | 17ms | 3048 KiB | ||||
10 | Wrong answer | 18ms | 3060 KiB | ||||
11 | Wrong answer | 17ms | 3044 KiB | ||||
12 | Wrong answer | 17ms | 3044 KiB | ||||
13 | Wrong answer | 50ms | 4880 KiB | ||||
14 | Wrong answer | 56ms | 4880 KiB | ||||
subtask4 | 0/15 | ||||||
15 | Wrong answer | 17ms | 2984 KiB | ||||
16 | Wrong answer | 18ms | 3108 KiB | ||||
17 | Wrong answer | 17ms | 3044 KiB | ||||
18 | Wrong answer | 18ms | 3108 KiB | ||||
19 | Wrong answer | 17ms | 3088 KiB | ||||
20 | Wrong answer | 18ms | 3044 KiB | ||||
21 | Wrong answer | 18ms | 2916 KiB | ||||
22 | Wrong answer | 17ms | 3064 KiB | ||||
23 | Wrong answer | 17ms | 3064 KiB | ||||
24 | Wrong answer | 17ms | 3084 KiB | ||||
subtask5 | 0/20 | ||||||
25 | Wrong answer | 19ms | 3172 KiB | ||||
26 | Wrong answer | 140ms | 3764 KiB | ||||
27 | Time limit exceeded | 1.026s | 3632 KiB | ||||
28 | Wrong answer | 495ms | 3684 KiB | ||||
29 | Time limit exceeded | 1.008s | 3724 KiB | ||||
30 | Wrong answer | 164ms | 3684 KiB | ||||
31 | Wrong answer | 456ms | 3728 KiB | ||||
32 | Wrong answer | 19ms | 3620 KiB | ||||
subtask6 | 0/15 | ||||||
33 | Wrong answer | 18ms | 3124 KiB | ||||
34 | Wrong answer | 86ms | 14572 KiB | ||||
35 | Time limit exceeded | 1.093s | 14784 KiB | ||||
36 | Time limit exceeded | 1.093s | 14848 KiB | ||||
37 | Time limit exceeded | 1.098s | 14696 KiB | ||||
38 | Time limit exceeded | 1.097s | 14848 KiB | ||||
39 | Time limit exceeded | 1.097s | 14700 KiB | ||||
40 | Wrong answer | 23ms | 4324 KiB | ||||
41 | Wrong answer | 79ms | 14624 KiB | ||||
subtask7 | 0/30 | ||||||
42 | Wrong answer | 93ms | 14376 KiB | ||||
43 | Wrong answer | 257ms | 14744 KiB | ||||
44 | Time limit exceeded | 1.098s | 14572 KiB | ||||
45 | Time limit exceeded | 1.095s | 14788 KiB | ||||
46 | Time limit exceeded | 1.098s | 14572 KiB | ||||
47 | Time limit exceeded | 1.098s | 14700 KiB | ||||
48 | Time limit exceeded | 1.098s | 14700 KiB | ||||
49 | Time limit exceeded | 1.098s | 14700 KiB | ||||
50 | Wrong answer | 105ms | 14496 KiB | ||||
51 | Wrong answer | 105ms | 14528 KiB |