Skip to content

Instantly share code, notes, and snippets.

@ebonneville
Created April 27, 2012 00:06
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save ebonneville/2504319 to your computer and use it in GitHub Desktop.
parseInt("10");
>> 10
parseInt("010");
>> 8
parseInt("010", 10);
>> 10
parseInt("10.9", 10);
>> 10
parseInt("i10");
>> NaN
parseInt("hi");
>> NaN
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment