something about binary numbers (20!!)

2006-12-27 7:28 pm
Here is my question:

If the Binary number is 11011,

why the decimal number is 27?

Can any one write the steps for change 11011 to 27 ?

I can just write:

1x2(4) + 1x2(3) + 1x0(2) + 1x1(1) + 1x1(0)
= 16 + 8 + 0 + 1 + 0
= 25

!!!!!!!!!!!!!!!!!!! Why ?

Can anyone answer my question?

20 points!

Please!!

I will have exam when I back school!

回答 (3)

2006-12-27 7:43 pm
✔ 最佳答案
因為你條數加錯左 ...

你寫既係:
1x2(4) + 1x2(3) + 1x0(2) + 1x1(1) + 1x1(0)
= 16 + 8 + 0 + 1 + 0
= 25

正確既係:
1x(2^4) + 1x(2^3) + 0x(2^2) + 1x(2^1) + 1x(2^0)
= 16 + 8 + 0 + 2 + 1
= 27

2^4 代表 2 既 4 次方 = 2 x 2 x 2 x 2.
2^3 代表 2 既 3 次方 = 2 x 2 x 2.
2^2 代表 2 既 2 次方 = 2 x 2.
2^1 代表 2 既 1 次方 = 2.
2^0 代表 2 既 0 次方, 即係 1.

如果都係覺得太難, 可以從右至左咁數: 1, 2, 4, 8, 16, 32, 64, 128, 256, ...(每次乘 2)
如果要轉既 number 寫住 "1", 就將數緊果個數加上去:

例如:
1000111 => 數既時候要數: 1, 2, 4, 8, 16, 32, 64
因為數 1, 2, 4 同 64 既時候 (記住: 右到左 !!!) 見到 "1",
所以將佢地加起黎 ...
1 + 2 + 4 + 64 = 71

明唔明呢?

2006-12-30 08:11:35 補充:
謝謝 ^___^
參考: 我寫左 20 年 program ...
2006-12-27 7:38 pm
11011 binary numbers from RIGHT to LEFT

the digit on the most right (最右邊) represents 2^0 which is 1
then the 2nd from the right represents 2^1 which is 2
the 3rd from the right represents 2^2 which is 4 and so on

Binary number
11011
Equals to
(2^4)*1 + (2^3)*1 + (2^2)*0 + (2^1)*1 + (2^0)*1
= 16 + 8 + 0 + 2 + 1
= 27.

Hope I have explained it clear enough.
2006-12-27 7:34 pm
The first digit is 2^0, the tenth digit is 2^1, the hundardth digit is 2^2, vice versa.
For 11011, the decimal number is:
= 2^4(1)+2^3(1)+2^2(0)+2^1(1)+2^0(1)
= 16+8+2+1
= 27


收錄日期: 2021-04-18 20:32:12
原文連結 [永久失效]:
https://hk.answers.yahoo.com/question/index?qid=20061227000051KK00924

檢視 Wayback Machine 備份