Example
In the example above, we use the same variable name in the main body and in the method name.
4. Find the current conversion rate for U.S. dollars to any three foreign currencies. Plan the logic for a program that allows the user to choose one of the three foreign currencies, input a dollar amount for conversion and view the converted amount.
Write 3 methods, one for each currency, each of which should input a dollar amount, perform the conversion and output the result.
The user can specify the foreign currency by its code, for example Japanese yen is JPY. Here is a list of exchange rates by code
Each conversion should take place in its own method.
5.Discuss the advantages to modularization. Think a real world problem you would design program logic to solve. Think of the sequential solution and then a modular solution. Discuss the advantages of the modular solution over the sequential solution.
This is worth 5 points.