answersLogoWhite

0


Best Answer

The first step is to use a function to convert the number (integer, floating point or otherwise) into a string. The next step is to convert each character within that string to its binary equivalent.

Converting an unsigned char to binary will require the use of bitwise operators, specifically &, << and >>. There are plenty of code snippets on the Web that show you how to accomplish this task, however it might be worth your while to work it out on paper first and then write the code.

The best recommendation at this point is to explore bitwise operators in C and understand how binary math works. You'll likely find many uses for this knowledge in the future.

User Avatar

Wiki User

11y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Which procedure is used to convert a string representation of a number into its binary value?
Write your answer...
Submit
Still have questions?
magnify glass
imp