users-prolog
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

reporting bug displaying real numbers


From: Erick Alphonse
Subject: reporting bug displaying real numbers
Date: Thu, 14 Jun 2001 14:41:06 -0400

Hello,

running gprolog-1.2.6 on an athlon-linux, I have the following outputs:

| ?- write(1.0).
1.0

yes
| ?- write(1.1).
1.1000000000000001

yes
| ?- write(1.2).
1.2

yes
| ?- write(1.3).
1.3

yes
| ?- write(1.4).
1.3999999999999999

and

| ?- 1.4 == 1.3999999999999999.

yes

and it will be the same with write/1, writeq/1, write_canonical/1,
display/1 and print/1.

That can be the source of big problems.
Erick.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]