|
|
вернуться в форумIt is 2 easy! isn`t it? Edited by author 20.05.2004 13:49 Re: It is 2 easy! YES it is But How to do it isn`t it? Edited by author 20.05.2004 13:49 Re: It is 2 easy! it seems easy but not too easy Re: It is 2 easy! Hi i wanto say that why my program gives error: here is my program: var k,n,x,y,z:longint; a:array[1..100000] of longint; b:array[1..100000] of longint; c:array[1..100000] of longint; begin readln(n); for k:=1 to n do readln(x,y); a[k]:=x; b[k]:=y; for k:=1 to n do begin c[k]:=((a[k]+b[k])+((a[k+1]+b[k+1]) div 10 ))mod 10; write(c[k]); end; end. Re: It is 2 easy! Your algo is wrong for this task sehvdi ozde kokunnen. Re: It is 2 easy! Послано Linus 16 авг 2006 01:31 You forgot to write begin...end operators after entering values (for k:=1 to n do begin read(x, y) ...) Else your algoritm seems me not correct. :) |
|
|