26th Sep 2019, 5:22 PM
Parto Ghahramani
Parto Ghahramani - avatar
9 Réponses
+ 9
You are treating integer 15 as a function. You need to use *, because if you strictly include parentheses ( ) after an integer, program assumes that you are calling the integer as a function. (You'll learn about functions in 3rd module of the Python 3 tutorial.) Just put * between 15 and (b-40) and your program should work fine.
26th Sep 2019, 5:39 PM
Seb TheS
Seb TheS - avatar
+ 5
Parto Ghahramani you are missing the asterisk symbol "*" for multiplication before the brackets in the print after else condition. Please look at the code https://code.sololearn.com/cq4nm41YkvAF/?ref=app
26th Sep 2019, 5:30 PM
TheWh¡teCat 🇧🇬
TheWh¡teCat 🇧🇬 - avatar
+ 3
oh thanks guys so much❤️
26th Sep 2019, 6:13 PM
Parto Ghahramani
Parto Ghahramani - avatar
+ 3
You should use a * symbol before (b-40) to show that you are multiplying 15 and (b-40) else 15 will be treated as a function.
28th Sep 2019, 9:30 AM
Abhijith Subash
Abhijith Subash - avatar
+ 2
b=int(input('how many hrs u work?')) if b<=40: print(10*b) else: print(10*40+15 * (b-40)) You missed a * between 15 and the bracket
27th Sep 2019, 9:44 AM
utoon enene
utoon enene - avatar
+ 2
You didn't use * between 15 and (b-40)
28th Sep 2019, 2:19 PM
Harsh Chauhan
Harsh Chauhan - avatar
+ 1
you miss the 15 next what operation you want to perform. It is either * or + Or ÷ or -
27th Sep 2019, 2:33 PM
Avijit Maity
Avijit Maity - avatar
+ 1
print(10*40+15*(b-40)) this is the correct way to write that statement....
27th Sep 2019, 6:29 PM
Naved Siddiki
Naved Siddiki - avatar
0
You missed a * between 15 and the bracket
29th Sep 2019, 7:21 AM
Dilji
Dilji - avatar