Skip to content

Commit af7613e

Browse files
committed
Update floating point tutorial
1 parent 66db937 commit af7613e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Doc/tutorial/floatingpoint.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ added onto a running total. That can make a difference in overall accuracy
192192
so that the errors do not accumulate to the point where they affect the
193193
final total:
194194

195-
>>> sum([0.1] * 10) == 1.0
195+
>>> 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 + 0.1 == 1.0
196196
False
197197
>>> math.fsum([0.1] * 10) == 1.0
198198
True

0 commit comments

Comments
 (0)