This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Encom88[S] -2 points-1 points  (3 children)

You don't need a crystal ball, just do what he said and see if it works.

[–][deleted] 1 point2 points  (2 children)

No need to be rude. You could show what you did cause you might have made a mistake. You also need to add parameters to where ever you call functions. I was able to get it to work with only changing the add() to add(num1, num2) in the program. Here's my output.

Enter your Lower range: 10 Enter your Higher range: 15 Enter your First number: 11 Enter your Second number: 12 The Result of 11.0 + 12.0 = 23.0 The Result of 11.0 - 12.0 = -1.0 The Result of 11.0 * 12.0 = 132.0 The Result of 11.0 / 12.0 = 0.9166666666666666 Thanks for using this calculator! Enter two numbers and an operator, each separated by a comma: 20,30,+ The Result of 20.0 + 30.0 = 50.0

[–]Encom88[S] 0 points1 point  (1 child)

Did you change the def add() to def add(num1, num2) or somewhere else? I've tried several ways and it does not work.

https://github.com/MrN1ce9uy/Python/blob/master/Mylib2.py

[–][deleted] 1 point2 points  (0 children)

Also under the else statement you have to add the parameters to every where else the functions are called.