Edit: The floating-point issue has been discussed previously (not only on this site, please see the links below). Therefore this question is essentially a duplicate, however it may be useful to link the well-known floating-point issue to floor division in R.
In this version of R
R version 3.6.3 (2020-02-29) -- "Holding the Windsock"
Copyright (C) 2020 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)
I have observed an inconsistency:
> 65 %/% 5
[1] 13
> 6.5 %/% .5
[1] 13
> .65 %/% .05
[1] 12
> .065 %/% .005
[1] 13
It may be a known issue probably related to floating-point arithmetic.
How to deal with this issue in everyday calculations in order to avoid wrong numbers?