Question: 1 . Using C + + , Write a program to covert a number among 3 numbering system binary, decimal, and hexadecimal. Your program will
Using C Write a program to covert a number among numbering system binary, decimal, and hexadecimal. Your program will ask user to enter a number with the base and convert to the other different bases.
Please do error checking for input.
i Wrong base, allow user to renter correct base.
ii Wrong number for each base and allow to renter correct number for the base.
Example:
Please enter a base :
Please enter a number:
Binary:
Decimal:
Hexadecimal: F
Please enter a base :
Please enter a number:
Binary:
Decimal:
Hexadecimal: F
Please enter a base :
Error: Illegal Base
Please enter correct base
Please enter a base :
Please enter a number:
Error: Illegal digit for the base
Please enter correct number for the base
Please enter a base :
Please enter a number:
Binary:
Decimal:
Hexadecimal:
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
