1. Menu-Driven Program
2. User has option to select 1 of 5 international currency types. (Canadian dollars, Mexican pesos, English pounds, Japanese yen, and French francs)
3. Program converts foreign currency to U.S. dollars if values provided are valid.
4. Program displays the equivalent dollar amount.
5. Program returns to main menu, user has option to enter another conversion or quit the program.
~Input-Process-Output Chart~
Input Process Output
Menu Options: User selects 1 of 6 Display Menu Currency Type (Integer) 1 - 5
International Value (Real) 0 - 1,000,000 Get Foreign Value Int_Value (Real) 0 - 1,000,000
Currency Type (Integer) 1 - 5
International Value (Real) 0 - 1,000,000 Convert Currency US_Value (Real) > 0
Currency Type (Integer) 1 - 5
International Value (Real) 0 - 1,000,000
US_Value (Real) > 0 Display Results Currency Type (Integer) 1 - 5
Int_Value (Real) 0 - 1,000,000
US_Value (Real) > 0
~Hierarchy Chart~
~Control Flow Diagram—Main Control~
~Control Flow Diagram—Display Menu~
~Control Flow Diagram—Get Foreign Value~
~Control Flow Diagram—Convert Currency~
~Control Flow Diagram—Display Results~
~Pseudocode~
Main Control
Declare Nation As String
Write "Welcome to the Currency Conversion Program"
Write
Write "This program coverts foreign currency to US dollars."
Repeat
Call Display Menu If Selection = 1 Then Set Nation = Canadian End If If Selection = 2 Then Set Nation = Mexican End If If Selection = 3 Then Set Nation = English End If If Selection = 4 Then Set Nation = Japanese End If If Selection = 5 Then Set Nation = French End If
Until Selection = 0
If Selection = 0 Then Write "Thank you for using the Currency Conversion Program" End Program
End If
Call Get Foreign Value
Call Convert Currency
Call Display Results End Main Control
Display