Created
October 7, 2017 12:38
-
-
Save MichelleDalalJian/061b4c2d8c7af108d520038c13a69f3b to your computer and use it in GitHub Desktop.
2.3 Write a program to prompt the user for hours and rate per hour using input to compute gross pay. Use 35 hours and a rate of 2.75 per hour to test the program (the pay should be 96.25). You should use input to read a string and float() to convert the string to a number. Do not worry about error checking or bad user data.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
xh = input("Enter Hours:") | |
xr = input("Enter Rate:") | |
xp = float(xh)*float(xr) | |
print("Pay:",xp) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment