I convert a decimal number into binary. My number is 66. I convert it like:
let bin1;
bin1 = Number(66).toString(2);
The result I get is bin1=1000010. So I get only 7 bits of the byte. I want to get all 8 bits of byte. So, I should get 01000010. What should I do to get so?