Jesus Torres
Eduardo Mendoza
Isaac Bernal
Juan Martinez
Programming Fundamentals I
10/24/2021
Algorithm
Step 1 - Function Prototypes
define 3 functions to call upon
o int binaryFunction(int) - will have the binary number conversion
o string RomanNumerals(string) - will have the roman numeral conversion process
o int HexDecimal(int) - will have the hexadecimal conversion process
Step 2 - Variables
create 3 variables to store our input
o num (int) - will hold the inputted number
o answerChoice (char) - will hold the character choice the user chooses when the
menu is displayed
o yesNo (char) - will hold the character choice the user chooses when asked if they
want to try again
Step 3 - Data Input
Output a menu asking the user to enter one of the choices displayed
Input the user data into answerChoice
Output a message asking the user to input a number from 1-50
Input the user data into the num variable
Step 4 - Data Validation
If answerChoice is not one of the choices, output “Wrong input option”
If num is not a number within the range, output “Wrong input number” and let user input
different number
If yesNo is a ‘y’ or a ‘Y’, display menu once again
Step 5 - Output Results
If the user chose ‘a’ or ‘A’, output ‘num’ as a roman numeral and a prompt asking the
user if they would like to convert another number.
If the user chose ‘b’ or ‘B’, output ‘num’ as a binary number and a prompt asking the
user if they would like to convert another number.
If the user chose ‘c’ or ‘C’, output ‘num’ as a hexadecimal and a prompt asking the user
if they would like to convert another number.
If the user chooses ‘d’, output an exit prompt