Question: pls help me with this problem! Project Description Your program must meet the following specifications 1. At program start, prompt the user for the original




pls help me with this problem!
Project Description Your program must meet the following specifications 1. At program start, prompt the user for the original currency 2. Then prompt the user for the target currency 3. Next prompt for the amount which must be an int 4. Setup the URL as explained below and send the request. 5. Convert the returned value to string, and then process it to find the converted value 6. Display the result to the user 7. Prompt the user if they want to repeat. Set up URL A sample URL is https://finance.google.com/finance/converter?a=100&from-USD&to-EUR You can put that link in a browser and see how Google currency converter converts 100 USD to EUR (convert $100 US to Euros). To change the amount or the currencies, you can simply replace those values in the URL by the values entered by the user. For this project, you can assume the user's currency input is always correct. You will need to check that the amount to be converted is correct. The URL needs to be a string for use in the urlopen (url) call below. You need to construct a URL string that has a value (such as 100 in sample URL above), the currency you are converting from (such as USD in the sample URL above) and the currency you are converting to (such as EUR in the sample URL above). You will be prompting for those three values so you need to insert them into your URL string. How do you do that? In Python we have the string format statement described in Section 4.4 of the text. Usually it is use inside a print () function, but it doesn't have to be Consider this code some str = "XYZ' someint = 123 a str = "abc { : d } de f {:s)" . format (some int, some str)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
