C - Base Converter
Description
Program takes in a value of a given base, then converts to the equivalent value in another given base.
Handles bases 2 through 16, as well as base 256.
Notes
Takes four arguments, separated by spaces:
- The given name of the program (Determined upon compilation. User Defined.)
- A value, to process.
- The base of the value (Should be of base 2-16, or 256.)
- The desired base to convert to (Should be of base 2-16, or 256.)
Known Issues
Program is meant to handle converting from any handled base to any other handled base, using three seperate potential algorithms.
Currently, all output is handled properly. However, input is only handled by two of the three given algorithms. Program technically still works, but input uses a less efficient "catch all" algorithm for powers of two.
Also, I'm sure this program is generally far less efficient than is optimal. Still trying to learn C. Can definitely be generally optimized at a later date, I just don't understand how, yet.