当前位置:网站首页>Binary to decimal, decimal to binary
Binary to decimal, decimal to binary
2022-07-03 08:37:00 【Jiamei no error】
Hexadecimal conversion
Binary to decimal

Decimal to binary


The rules
One 、 Other decimal system to decimal system
1. Binary to decimal
The rules : Let's start at the lowest point ( On the right ), Extract the number in each bit , multiply 2 Of ( digit -1) Power , Then sum it
Example :1010 Convert to decimal
1010 ===> 0X2 1-1 + 1X22-1 + 0X23-1 + 1X24-1 = 10
2. Octal to decimal
The rules : Let's start at the lowest point ( On the right ), Extract the number in each bit , multiply 8 Of ( digit -1) Power , Then sum it
Example : 17 Convert to decimal
17 ===> 7X81-1 + 1X82-1 = 7 + 8 = 15
3. Hexadecimal to decimal
The rules : Let's start at the lowest point ( On the right ), Extract the number in each bit , multiply 16 Of ( digit -1) Power , Then sum it
Example :1AF Convert to Decimal system
1AF ===> 15X161-1 + 10X162-1 + 1X 163-1 = 15+160+256= 431
Two 、 Decimal to other bases
The rules : Divide the number that needs to be converted by 2/8/16( Binary system / octal / Hexadecimal ), Until Shang Wei 0, Then reverse the remainder of each step to the corresponding hexadecimal number
边栏推荐
- Osganimation library parsing
- [rust notes] 08 enumeration and mode
- VIM learning notes from introduction to silk skating
- [concurrent programming] synchronization container, concurrent container, blocking queue, double ended queue and work secret
- 注解简化配置与启动时加载
- Unity Editor Extension - Outline
- 使用base64编码传图片
- Conversion between golang JSON format and structure
- Golang's range
- Unity editor expansion - window, sub window, menu, right-click menu (context menu)
猜你喜欢

详解sizeof、strlen、指针和数组等组合题

100 GIS practical application cases (78) - Multi compliance database design and data warehousing

C course design employee information management system

MXone Pro自适应2.0影视模板西瓜视频主题苹果cmsV10模板

Cloudcompare learning (1) - cloudcompare compilation and common plug-in implementation

Base64和Base64URL
![[concurrent programming] consistency hash](/img/5e/3d0a52caa8ca489a6e6267274bbb39.jpg)
[concurrent programming] consistency hash

Introduction to Base64 coding

Visual Studio (VS) shortcut keys

单调栈-42. 接雨水
随机推荐
Solution détaillée de toutes les formules de fonction de transfert (fonction d'activation) du réseau neuronal MATLAB
【Rust 笔记】12-闭包
Find the intersection of line segments
[rust notes] 02 ownership
Dealing with duplicate data in Excel with xlwings
Unity Editor Extension - drag and drop
UE4 source code reading_ Mobile synchronization
Markdown directory generation
Cesium for unreal quick start - simple scenario configuration
Downward compatibility and upward compatibility
Display terrain database on osgearth ball
简易入手《SOM神经网络》的本质与原理
Monotonic stack -503 Next bigger Element II
UE4 source code reading_ Bone model and animation system_ Animation node
Un système de gestion de centre commercial pour la conception de cours de technologie d'application de base de données
Graphics_ Games101/202 learning notes
Constraintlayout's constraintset dynamically modifies constraints
[concurrent programming] working mechanism and type of thread pool
Conversion between golang JSON format and structure
Pit & ADB wireless debugging of vivo real machine debugging