Reference no: EM132208346
Write a program (with c only) to implement a simple currency converter program.
Commands are as follows:
Euro-US
US-Euro
Euro-Pound
Pound-Euro
Pound-US
US-Pound
showrates
quit
Note that the commands are EXACTLY as shown. Capital letters and lower case letters as shown. There is a very good reason for this requirement, as will become clear later in the semester.
Commands work as follows:
Euro-US
requests a currency amount in Euros
converts that into a currency amount in $US.
US-Euro
reverse the above; request an amount in $US, convert it into Euros
Euro-Pound, Pound-Euro
same thing for converting Pound Sterling to Euros and vice versa
Pound-US, US-Pound
same thing for converting Pound Sterling to $US and vice versa
showrates
shows the exchange rates used in an appropriate way
quit
exit the program
Use the following currency exchange rates (taken from Monday, August 26, 2013)
$1.0000 US = 0.74759 Euro
$1.0000 US = 0.64173 Pound Sterling