SF week 2‐Lab Journal Entry ‐ Data Types and Representation - Wudong-champlain/Spring2024 GitHub Wiki
- In your own words, explain the process of converting binary to decimal. (2 points)
To convert a binary to a decimal we multiply the binary number with 2^0, And add 1 to the 0 each time we move to a different position for example: 0101
2^0 x 1=1 2^1 x 0=0 2^2 x 1=4 2^3 x 0=0
So the binary number 0101 is equal to the decimal number 5
- In your own words, explain the process of converting hexadecimal to decimal. (2 points) For hexadecimal after number 0-9 we go to A-F, to convert then to a decimal number we multiply each digit with its corresponding power of 16 and then add together. So for example: (A1)base 16 to convert we do A=10 (10x16^1)+ (1x16^0)=161