A few questions(+)

1.The prob says we can only place '+','#','A'..'Z' on the tape. So can't we place '-'? But the sample output places '-'!

2.What's the range for condition?

So I don't understand why my prog gets WA:

program ural1231;

const

maxn=200;

var

remain:array[1..maxn]of byte;

k,i:byte;

begin

read(k);

remain[1]:=1;

for i:=2 to maxn do begin

remain[i]:=(remain[i-1]+k) mod i;

if remain[i]=0 then remain[i]:=i;

end;

writeln('1 # 1 # >');

for i:=1 to maxn do

writeln(i,' - ',i+1,' + >');

for i:=1 to maxn do

writeln(i+1,' # ',1000+i-remain[i],' # <');

for i:=1 to maxn do

writeln(1000+i,' + ',999+i,' + <');

writeln('1000 + 1000 - =');

end.