|
|
back to boardTEST N4 asis!!!!!! Help PLEASE TEST N4 asis!!!!!! Help PLEASE Re: TEST N4 asis!!!!!! Help PLEASE var a:array[1..50001]of integer; n,i,j,k,m:longint; begin read(n); for i:=1 to n do read(a[i]); read(m); for i:=1 to m do begin read(k); for j:=1 to n do if (a[j]+k=10000) then begin write('YES'); halt(0); end; end; write('NO'); end. TEST N4 asis!!!!!! Help PLEASE Re: TEST N4 asis!!!!!! Help PLEASE Posted by Madhav 13 Jun 2008 02:03 I don't know pascal but i feel that once you have found the value you print "YES" and end the program WITHOUT taking the Entire input |
|
|