JavaScript's parseInt function just decided that 0.0000005 equals 5 because scientific notation turned it into "5e-7" and parseInt grabbed just the "5" like a toddler picking only the M&Ms out of trail mix. Six decimal places? Nah, too much work. Five? Still zero. Seven? BOOM, suddenly 5. It's like JavaScript was programmed by someone rolling dice to determine behavior. No wonder developers drink.
Someone Explain This To Me Like Im Five
9 months ago
279,327 views
0 shares
javascript-memes, parseint-memes, bugs-memes, floating-point-memes, scientific-notation-memes | ProgrammerHumor.io
More Like This
Is It Going To Be Recursive Gil
2 years ago
108.5K views
0 shares
I am aware that semicolons are not used in JSON.
4 years ago
132.3K views
0 shares
Rip Hello World
11 months ago
132.5K views
0 shares
Who else loves Regex?
3 years ago
117.8K views
0 shares
Somebody check on python ๐
2 years ago
110.9K views
0 shares
This Is Javascript
11 days ago
224.0K views
2 shares
Loading more content...
AI
AWS
Agile
Algorithms
Android
Apple
Bash
C++
Csharp