This commit is contained in:
Jonas Maebe 2005-02-28 12:06:39 +00:00
parent 1162235207
commit a8f2c6e5f7

31
tests/webtbs/tw3708.pp Normal file
View File

@ -0,0 +1,31 @@
program prec;
uses SysUtils;
var
i:Integer;
v: Double;
s: string;
begin
v := 1.0000000000001;
for i := 1 to 20 do
begin
s := FloatToStrF(v, ffGeneral, i, 0);
WriteLn(i, ' ', s);
if (i < 13) then
begin
if (s <> '1') then
begin
writeln('error');
halt(1);
end;
end
else
if (s <> '1.0000000000001') then
begin
writeln('error');
halt(1);
end;
end;
end.