Which binary number equals decimal 9?

Enhance your programming skills with the RECF Programming Test. Features flashcards and multiple choice questions with hints and explanations. Prepare for success!

Multiple Choice

Which binary number equals decimal 9?

Explanation:
Binary numbers use powers of two for each position, with the rightmost digit as 2^0, the next as 2^1, then 2^2, and so on. For the string 1001, there are 1s in the 2^3 and 2^0 places, so the value is 2^3 + 2^0 = 8 + 1 = 9. That matches decimal nine. The other patterns correspond to different sums: 1000 is 2^3 = 8, 1010 is 2^3 + 2^1 = 8 + 2 = 10, and 1111 is 2^3 + 2^2 + 2^1 + 2^0 = 8 + 4 + 2 + 1 = 15.

Binary numbers use powers of two for each position, with the rightmost digit as 2^0, the next as 2^1, then 2^2, and so on. For the string 1001, there are 1s in the 2^3 and 2^0 places, so the value is 2^3 + 2^0 = 8 + 1 = 9. That matches decimal nine. The other patterns correspond to different sums: 1000 is 2^3 = 8, 1010 is 2^3 + 2^1 = 8 + 2 = 10, and 1111 is 2^3 + 2^2 + 2^1 + 2^0 = 8 + 4 + 2 + 1 = 15.

Subscribe

Get the latest from Passetra

You can unsubscribe at any time. Read our privacy policy