Why does 00.0 cause a syntax error?
问题 This is weird. This is what happens at the JavaScript console in Chrome (version 42.0.2311.135, 64-bit). > 0 < 0 > 00 < 0 > 0.0 < 0 > 00.0 X Uncaught > SyntaxError: Unexpected number Firefox 37.0.2 does the same, although its error message is: SyntaxError: missing ; before statement There's probably some technical explanation regarding the way JavaScript parses numbers, and perhaps it can only happen when tinkering at the console prompt, but it still seems wrong. Why does it do that? 回答1: The