Skip to content

Commit

Permalink
Update div.jl
Browse files Browse the repository at this point in the history
I think there was a minor typo in the doc here.
  • Loading branch information
tthsqe12 authored Jul 21, 2021
1 parent ed93e30 commit 99e8208
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion base/div.jl
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ What is happening here is that the true value of the floating-point number writt
as `0.1` is slightly larger than the numerical value 1/10 while `6.0` represents
the number 6 precisely. Therefore the true value of `6.0 / 0.1` is slightly less
than 60. When doing division, this is rounded to precisely `60.0`, but
`fld(6.0, 0.1)` always takes the floor or the true value, so the result is `59.0`.
`fld(6.0, 0.1)` always takes the floor of the true value, so the result is `59.0`.
"""
fld(a, b) = div(a, b, RoundDown)

Expand Down

0 comments on commit 99e8208

Please sign in to comment.