|
|
вернуться в форумcraiovaacm "craiovaacm" this is the code you gave me: {Simple Calculations-1047} var a,c:array [0..3001] of real; i,n,k:integer; begin while not(eof) do begin readln(n); readln(a[0]); readln(a[n+1]); for i:=1 to n do readln(c[i]); for k:=n downto 1 do begin a[k]:=a[0]; for i:=k downto 1 do a[k]:=a[k] - I*2*c[i]; a[k]:=a[k]+k*a[k+1]; a[k]:=a[k]/(k+1); end; writeln(a[1]:0:2); end; end. I post it and get Wrong Answer, is something else wrong with the code |
|
|