Submission #7062937


Source Code Expand

a, b, c, x = [int(input()) for _ in range(4)]
count=0
a2 = x // 500 #500円玉は何枚必要か
if a < a2: #足りない時
    a3 = a
else: #足りてる時
    a3 = a2
for i in range(a3+1):
    y = x -500*i
    b2 = y//100
    if b < b2:
        b3 = b
    else:
        b3 = b2
        for j in range(b3+1):
            z = y -100*j
            if z % 50 == 0 and z /50 <= c:
                count += 1
            else:
                pass
print(count)

Submission Info

Submission Time
Task B - Coins
User nikorasunakeizi
Language Python (3.4.3)
Score 0
Code Size 478 Byte
Status WA
Exec Time 17 ms
Memory 3064 KB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 0 / 200
Status
AC × 2
WA × 1
AC × 8
WA × 5
Set Name Test Cases
Sample sample01.txt, sample02.txt, sample03.txt
All 01.txt, 02.txt, 03.txt, 04.txt, 05.txt, 06.txt, 07.txt, 08.txt, 09.txt, 10.txt, sample01.txt, sample02.txt, sample03.txt
Case Name Status Exec Time Memory
01.txt AC 17 ms 3060 KB
02.txt AC 17 ms 3064 KB
03.txt AC 17 ms 3064 KB
04.txt WA 17 ms 3064 KB
05.txt AC 17 ms 3060 KB
06.txt WA 17 ms 2940 KB
07.txt WA 17 ms 2940 KB
08.txt AC 17 ms 2940 KB
09.txt WA 17 ms 3060 KB
10.txt AC 17 ms 3060 KB
sample01.txt AC 17 ms 3064 KB
sample02.txt AC 17 ms 3060 KB
sample03.txt WA 17 ms 3064 KB