Skip to main content

Home/ javascript/ Group items tagged cast

Rss Feed Group items tagged

Javier Neira

7 + 8 === 7 in JavaScript » Debuggable Ltd - 0 views

  • JavaScript assumes that any 0-prefixed string ought to be referring to an octal number. This will not become apparent until your string represents an invalid octal such as '08'. So in order to outsmart this "feature" you have to explicitly provide the base for your integer:
1 - 1 of 1
Showing 20 items per page