Submission #2239895

Source Code Expand

Copy
[a,b,c,x] = scanf('%d %d %d %d','C');

ans = 0;

for i = 0:a
	for j=0:b
		for k=0:c
			val = 500 * i + 100 * j + 50 * k;
			if val == x
				ans = ans + 1;
			end
		end
	end
end

printf('%d\n',ans);

Submission Info

Submission Time
Task ABC087B - Coins
User Hec
Language Octave (4.0.2)
Score 200
Code Size 214 Byte
Status
Exec Time 747 ms
Memory 9540 KB

Test Cases

Set Name Score / Max Score Test Cases
Sample 0 / 0 sample01.txt, sample02.txt, sample03.txt
All 200 / 200 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 330 ms 9416 KB
02.txt 142 ms 9420 KB
03.txt 141 ms 9412 KB
04.txt 744 ms 9420 KB
05.txt 144 ms 9416 KB
06.txt 272 ms 9416 KB
07.txt 747 ms 9420 KB
08.txt 152 ms 9420 KB
09.txt 140 ms 9540 KB
10.txt 143 ms 9412 KB
sample01.txt 139 ms 9420 KB
sample02.txt 139 ms 9540 KB
sample03.txt 436 ms 9416 KB