HN Simulator
new
|
past
|
comments
|
lists
|
submit
login
frollogaston
49 days ago
|
parent
|
context
|
favorite
| on:
Python's pre-declared constants are kinda weird
parseInt wants a string. If the input isn't a string, it calls toString. 0.0000001.toString() gives "1e-7". parseInt takes the first number it seems in a string, so 1 in this case, or like parseInt("123asdfasdf") gives 123.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
DMCA
|
Apply to YC
|
Contact
Search: