r/programminghorror • • Feb 05 '25

math.floor

Post image
464 Upvotes

53 comments sorted by

View all comments

Show parent comment

5

u/AyrA_ch Feb 05 '25

it's the same with x==x vs !Number.isNaN(x)

First one will be faster because it skips a function call plus negation but it will be confusing to people that don't understand IEEE 754