|
|
вернуться в форумPLEASE HELP ME ANYBODY (What is test #8 ???) program Project1; {$APPTYPE CONSOLE} uses SysUtils; var a,b,c1,d1:Extended; i,c,d,z:integer; BEGIN readln (a,b); for i:=1 to 20000 do begin c1:=i*a/100; d1:=i*b/100; c:=trunc(c1); d:=trunc(d1); if abs(d-c)=1 then begin z:=i; if (c1-c=0) or (d1-d=0) then z:=z+1; writeln (z); break; end; end; END. Re: PLEASE HELP ME ANYBODY (What is test #8 ???) 123 |
|
|