11. parseInt() function



Hello guys!
I'm confused a little bit about the usage of the parseInt() function here. I understand that it should take the input from the keyboard and transform it somehow to the integer, probably in the decimal number system cause we have "10" as the second argument for the parseInt().
Am I right?


Second argument in that function is numerical base you want to use, 10 is representing standard decimal base.
You have to be careful because you can easily get NaN (Not a Number) if you try to parse text (but parsing "F" into base 16 will work for example).


I see, thank you for answering!