Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
14
Task/McNuggets-problem/XPL0/mcnuggets-problem.xpl0
Normal file
14
Task/McNuggets-problem/XPL0/mcnuggets-problem.xpl0
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
int N, A(101), X, Y, Z;
|
||||
[for N:= 0 to 100 do A(N):= false;
|
||||
for X:= 0 to 100/6 do
|
||||
for Y:= 0 to 100/9 do
|
||||
for Z:= 0 to 100/20 do
|
||||
[N:= 6*X + 9*Y + 20*Z;
|
||||
if N <= 100 then A(N):= true;
|
||||
];
|
||||
for N:= 100 downto 0 do
|
||||
if A(N) = false then
|
||||
[IntOut(0, N);
|
||||
exit;
|
||||
];
|
||||
]
|
||||
Loading…
Add table
Add a link
Reference in a new issue