|
|
back to boardWhy I got 'FLT_INVALID_OPERATION' ? Posted by Tang RZ 14 Jul 2004 09:25 This is my program: var a,temp,n,p:longint; begin read(n); temp:=round((-1+trunc(sqrt(1+8n))+1)/2); for p:=temp downto 1 do if trunc(((2*n/p)-p+1)/2)=(((2*n/p)-p+1)/2) then begin a:=trunc(((2*n/p)-p+1)/2); writeln(a,' ',p); halt; end; writeln(n,' ',1); end. What's wrong? Can you help me? Edited by author 14.07.2004 09:46 Re: Why I got 'FLT_INVALID_OPERATION' ? Posted by Tang RZ 16 Jul 2004 06:11 I got AC. |
|
|