+ 1

Binary to string

What is the algorithm to convert a binary code to string?

31st Jan 2018, 10:14 PM
Daniel Batiz
Daniel Batiz - avatar
2 odpowiedzi
0
Well characters are one byte. So if you have like 64bit long binary sequence you could just take the first 8 bits and convert it to ascii. Then second byte and third etc... 8 characters from 64bits Here’s string ”hello” as binary 0110100001100101011011000110110001101111 First 8 bits from the left are 01101000 it’s 104 in decimal and letter ”h” in ascii table.
31st Jan 2018, 11:00 PM
Toni Isotalo
Toni Isotalo - avatar