Help me understand binary to integer, radix and base?

Tell us what’s happening:
New to programming here. Please explain what this curriculum is about. And I did not understand the base thing at all.
Thanks.
Your code so far


function convertToInteger(str) {

}

convertToInteger("10011");

Your browser information:

User Agent is: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36.

Challenge: Use the parseInt Function with a Radix

Link to the challenge:

we usually count in base 10 (1,2,3,4,5,6,7,8,9,10…), it’s called base ten because there are ten numbers used.
Base 2 uses only 2 numbers: 0 and 1
so you have 0, 1 , 10, 11, 100, 101 etc

you use the base to indicate that the given number is not in base 10, and to let know from which base needs to be converted

1 Like