[Tutor] float.is_integer()
Alan Gauld
alan.gauld at yahoo.co.uk
Sat Oct 3 05:51:34 EDT 2020
On 03/10/2020 01:08, Zachary Ware wrote:
> Have a look at the repr of 23444444444444444.7777; a 64 bit floating point
> number cannot represent that number exactly.
So basically the float is just too big to include the fractional part.
Hmm, I wonder where the break off point is? Time to do some math...
Or play with the interpreter! :-)
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos
More information about the Tutor
mailing list