|
|
вернуться в форумWhy my program get wrong answer?(I think it's right) var s,before,bf,i,n:longint; max:comp; begin readln(n); readln(bf); readln(before); max:=before*1.0-bf; s:=1; for i:=3 to n do begin readln(bf); if bf*1.0-before>max then begin s:=i-1; max:=bf*1.0-before; end; before:=bf; end; writeln(s,' ',s+1); end. Re: Why my program get wrong answer?(I think it's right) For some strange reason, only c++ sources get AC Re: Why my program get wrong answer?(I think it's right) Послано hello 6 май 2004 15:26 Why ? |
|
|