DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
compare if 2 numbers are relatively equal
from math import isclose a = 1.0 b = 1.00000001 isclose(a, b, rel_tol=1e-9, abs_tol=0.0)
Source by stackoverflow.com #
PREVIOUS
NEXT
Tagged:
#compare
#numbers
#equal
ADD COMMENT
Topic
COMMENT
Name
4+8 =
Submit