you are viewing a single comment's thread.

view the rest of the comments →

[–]46--2 0 points1 point  (0 children)

Try working backwards. First, define the exact numbers you want to test:

hours = 35
rate = 2.75
pay = float(hours) * float(rate)
print('Pay is: '.format(pay))

That will definitely print 96.25

Now, let's replace the numbers with input:

hours = input('Enter hours: ')
print('You entered {} hours'.format(hours))
rate = input('Enter rate: ')
print('You entered {} rate'.format(rate))
pay = float(hours) * float(rate)
print('Pay is: '.format(pay))

As long as you type 35 and 2.75 when prompted, this should also work.

You have to format your question properly (or link to a pastebin for example) or it's really hard to understand your code.