Convert from Text to Binary

Convert from Text to Binary

The relationship between ASCII encoded text and the bin value of the characters is described in the ASCII table. It descripes the mapping between each character and a 7 bit value, with will be converted to bin.

Example: M => binary
M => 77 (with ASCII Table)
77 / 2^7 = 77 / 128 = 0 (first bin digit)
77 % 2^7 = 77
77 / 2^6 = 77 / 64 = 1 (second bin digit)
77 % 2^6 = 13
13 / 2^5 = 13 / 32 = 0
13 % 2^5 = 13
13 / 2^4 = 13 / 16 = 0
13 % 2^4 = 13
13 / 2^3 = 13 / 8 = 1
13 % 2^3 = 5
5 / 2^2 = 5 / 4 = 1
5 % 2^2 = 1
1 / 2^1 = 1 / 2 = 0
1 % 2^1 = 1
1 / 2^0 = 1 / 1 = 1
1 % 2^0 = 0
=> 0b01001101 (= 77)