8
计算机中的单位转化及二进制的计算方法
source link: https://blog.51cto.com/u_15740457/5558289
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
计算机中的单位转化及二进制的计算方法
原创以上是多少字节(计算机单位)
bit-比特位 一个比特位是存放一个二进制位
byte-字节
1byte=8bit(特殊),其余都是1024进行换算。
例子:short是2个字节,也就是2*8=16个比特位,转化为二进制位。所以一共有2^16种状态,范围是0~2^16-1(区分!!!)
00000000000000=0(十进制)
00000000000001=1
...............
1111111111111111=2^16
Tip:110=1*2^2+1*2^1+0*2^0=7
综上为个人整理笔记,若有纰漏,敬请指导!
- 1赞
- 收藏
- 评论
- 分享
- 举报
上一篇:编程萌新的内心独白
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK