Python ExchangeRate API Lab Level Up
-
Allow the user to input the
base currencyand thetarget currency.- Modify your code to accept user input for both values
- Update the API URL to accept dynamic values
-
Do the calculation for them.
-
Allow the user to input an amount in the base currency and calculate the equivalent amount in the target currency.
Hint: Check out this resource for formatting numeric values in f strings in Python: Python String Formatting Mini-Language
-
-
Error Handing
- Handle invalid currency codes and API errors gracefully.