Bryce H.

asked • 01/22/23

how to write a program in python that takes the coin value entered and spits out what coin that is

Write a program that asks the user for the value of a coin. Then determine what kind of coin they entered using this information.

 

1 = “Penny”

5 = “Nickle”

10 = “Dime”

25 = “Quarter”

50 = “Half dollar”

 

Provide a message if you enter any other value that does not match.

 

Sample 1:

Enter a coin value: 1

That’s a penny!

 

Sample 2:

Enter a coin value: 80

That’s not a valid coin!

 


1 Expert Answer

By:

Bradley T. answered • 01/23/23

Tutor
5 (4)

Tutor for Python and High School and Middle School Math

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.