program fjf77;
var
  a:integer;
  b,c:longreal;
  d:longreal=1e4000;  (* Not all machines support this *)
  e:longreal=1e-4000;
begin
  b:=1; for a:=1 to 4000 do b:=b*10;
  c:=1; for a:=1 to 4000 do c:=c/10;
  {$field-widths}
  if ( abs ( b / d - 1 ) < 1E-15 )
     and ( abs ( c / e - 1 ) < 1E-15 ) then
    writeln ( 'OK' )
  else
    writeln('failed: ',b,c,d,e)
end.
