令人困惑的MB與MB S

2022-02-08 06:28:17 字數 577 閱讀 6573

只要是對計算機有了解的同學一定都知道位元組有如下換算關係:

1 byte (b) = 8 bits (b) 位元組=8個二進位制位 

1 kilobyte(k/kb)=210 bytes=1,024 bytes 千位元組

1 megabyte(m/mb)=220 bytes=1,048,576 bytes 兆位元組

1 gigabyte(g/gb)=230 bytes=1,073,741,824 bytes 千兆位元組

1 terabyte(t/tb)=240 bytes=1,099,511,627,776 bytes吉位元組

當然,如果你在學習計算機網路或是組成原理cpu等的傳輸率的時候,會經常出現如下單位:1mb/s,

比如要計算:(1mb/s)/4b,答案是2.5*105,因為這裡的mb不在是上面提到的210kb,而是106b

原來,在計算機界,表示儲存容量或是檔案大小的時候,k=210=1024,m=220,……

但是,涉及到有關通訊等傳輸速率的時候,就有後面提到的轉換關係了:

kb/s=103b/s       mb/s=106b/s        gb/s=109b/s ……

令人困惑的strtotime

經常會有人被strtotime結合 1 month,1 month,next month的時候搞得很困惑,然後就會覺得這個函式有點不那麼靠譜,動不動就出問題.用的時候就會很慌 這不,剛剛就有人在微博上又問我 鳥哥,今天是2018 07 31 執行 date y m d strtotime 1 mon...

令人困惑的strtotime

經常會有人被strtotime結合 1 month,1 month,next month的時候搞得很困惑,然後就會覺得這個函式有點不那麼靠譜,動不動就出問題.用的時候就會很慌 這不,剛剛就有人在微博上又問我 今天是2018 07 31 執行 date y m d strtotime 1 month ...

令人困惑的C 語法

include include for size t using namespace std arr 13 run error in vs.net template struct myhash stl template null struct myhash stl template null str...