Program fordimon;
var n,k,i,j:integer;
s:array[1..10] of integer;
begin
assign(input,'task2.txt');
reset(input);
readln(n,k);
close(input);
assign(output,'task2.out');
rewrite(output);
for i:=1 to n doif i<=k then s[i]:=1 <br>else s[i]:=0;for i:=2 to n do
begin
j:=i-1;
while (j>0) and (j>=i-k) do
begin
s[i]:=s[i]+s[j];
j:=j-1endend;
write(s[n]);
close(output)
end.