Explore BrainMass
Share

Explore BrainMass

    C library: hex to octal representation conversion

    This content was COPIED from BrainMass.com - View the original, and get the already-completed solution here!

    Is their a built-in function in C that can be used to convert hexadecimal representation of a number to octal representation?

    © BrainMass Inc. brainmass.com October 9, 2019, 7:23 pm ad1c9bdddf
    https://brainmass.com/computer-science/c/library-hex-octal-representation-conversion-116589

    Solution Preview

    There is no single built-in function for the purpose, however you can use combination of scanf and printf family of functions (printf/scanf/fprintf/fscanf/sprintf/sscanf) to achieve the goal.

    use format specification "%x" during scanning the ...

    Solution Summary

    Solution gives a small C program that demonstrates how to read a number in hexadecimal representation and output it in octal representation?

    $2.19