Question: Write a C programme that converts a number given in base bi to another base bo requested by the user. The output of the programme

Write a C programme that converts a number given in base bi to another base bo requested by the user.

The output of the programme should look something like this:

Please enter the number N to be converted:

34

Please enter the input base (the base of the number to be converted):

8

Please enter the output base (the base into which the number is to be converted):

10

Assume that the number N to be converted is specified as a string for example ike 123A (base:16) or 34 (base 5) and also allow numbers with decimal points and negative numbers to be converted as well.The final result should also be a string like 11001 or -457.The input and output bases should be integers.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!