Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/ibrahimbougaoua/octal

Decimal to Octal converter
https://github.com/ibrahimbougaoua/octal

Last synced: 11 days ago
JSON representation

Decimal to Octal converter

Awesome Lists containing this project

README

        

# octal
Decimal to Octal converter

Conversion steps:

Divide the number by 8.
Get the integer quotient for the next iteration.
Get the remainder for the binary digit.
Repeat the steps until the quotient is equal to 0.

Decimal to octal conversion examples
(24)10 = (30)8
(112)10 = (160)8
(2048)10 = (4000)8

Decimal Octal
0 0
1 1
2 2
3 3
4 4
5 5
6 6
7 7
8 10
9 11
10 12
11 13
12 14
13 15
14 16
15 17
16 20