|  | 
|  | 
| back to board | Why I got WA 3 Posted by Friends  11 Oct 2008 17:48HERE is my code
 var
 n,m,i,k:integer;
 x,y:array [1..10000] of integer;
 begin
 readln(n,m);
 k:=0;
 for i:=1 to m do
 begin
 readln(x[i],y[i]);
 if abs(x[i]-y[i])=1 then k:=k+1;
 if abs(x[i]-y[i])=n-1 then k:=k+1;
 end;
 if (k=n) and (k<=m) then writeln('Luck is possible')
 else
 writeln('Unlucky Petr');
 readln;
 readln;
 end.
Re: Why I got WA 3 i think you haven't understood the task correctly. If you are interested, write to i.ju.olshvang[at]gmail[dot]com or icq#344303921, i'll try to make it clear to you.Re: Why I got WA 3 Tell me please! | 
 | 
|