電腦相關單位換算關係的積累

來源:互聯網
上載者:User

1 Byte = 2^0 Byte = 8 Bit

1 KB = 2^10 Byte = 1024 Byte

1 MB = 2^20 Byte =  2^10 KB  = 1024*1024 Byte

1 GB = 2^30 Byte =  2^10 MB  = 1024*1024*1024 Byte

1 TB = 2^40 Byte

1 PB = 2^50 Byte

1 EB = 2^60 Byte

1 ZB = 2^70 Byte

1 YB = 2^80 Byte

 

2^32 Byte= 4*1 GB = 4GB

2^16 Byte = 2^10 * 2^6 Byte= 64 KB

 

1 DWORD = 2 WORD = 4 Byte

1 WORD = 2 Byte

注意,這裡的WORD和電腦的字長不是一個概念,32位處理器的字長為32位,也就是4個位元組,64位處理器的字長是64個二進位位,是八個位元組。

字長的概念是電腦技術中對CPU在單位時間內(同一時間)能一次處理的位元的位元

 

而WORD和DWORD在WINDEF.H中有如下定義:

typedef unsigned char       BYTE; // 一個位元組
typedef unsigned short      WORD; //兩個位元組
typedef unsigned long       DWORD; //四個位元組

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.