2348 | 2023-01-10 22:21:05 | kristof | Bevásárlás | python3 | Accepted 100/100 | 17ms | 13580 KiB |
A = int(input())
B = int(input())
C = int(input())
aMin = 0
bMin = 0
cMin = 0
osszeg = 0
aMin = min(A, 10)
if aMin < 10:
bMin = min((10-aMin), B)
if aMin + bMin < 10:
cMin = min(10-(aMin+bMin), C)
if A + B + C < 10:
print(-1)
else:
print(aMin * 300+ bMin * 350 + cMin *400)
Subtask | Sum | Test | Verdict | Time | Memory | ||
---|---|---|---|---|---|---|---|
subtask1 | 0/0 | ||||||
1 | Accepted | 17ms | 11116 KiB | ||||
2 | Accepted | 17ms | 11444 KiB | ||||
3 | Accepted | 16ms | 11728 KiB | ||||
subtask2 | 10/10 | ||||||
4 | Accepted | 16ms | 11908 KiB | ||||
5 | Accepted | 16ms | 11852 KiB | ||||
6 | Accepted | 17ms | 12204 KiB | ||||
subtask3 | 20/20 | ||||||
7 | Accepted | 16ms | 11908 KiB | ||||
8 | Accepted | 17ms | 12220 KiB | ||||
9 | Accepted | 17ms | 12292 KiB | ||||
10 | Accepted | 16ms | 12344 KiB | ||||
subtask4 | 30/30 | ||||||
11 | Accepted | 17ms | 12400 KiB | ||||
12 | Accepted | 17ms | 12352 KiB | ||||
13 | Accepted | 17ms | 12388 KiB | ||||
14 | Accepted | 17ms | 12624 KiB | ||||
subtask5 | 40/40 | ||||||
15 | Accepted | 17ms | 13104 KiB | ||||
16 | Accepted | 17ms | 12932 KiB | ||||
17 | Accepted | 17ms | 13236 KiB | ||||
18 | Accepted | 17ms | 13308 KiB | ||||
19 | Accepted | 17ms | 13324 KiB | ||||
20 | Accepted | 17ms | 13580 KiB |