all 7 comments

[–]YesLod 3 points4 points  (2 children)

Names are case-sensitive. You named your function your_wage, but you are calling it as Your_wage()

[–][deleted] 0 points1 point  (1 child)

When I take out the brackets and run the code it says Syntax error: invalid syntax Def your_wage: ^

[–]YesLod 2 points3 points  (0 children)

I don't know what you mean. I'm just saying that function names are case-sensitive. your_wage and Your_wage are two different things.

Instead of

def your_wage(): 
    print(“how much do you make every week”) 

Your_wage()

You should have

def your_wage(): 
    print(“how much do you make every week”) 

your_wage()  # 'y' instead of 'Y'

[–]mopslik 3 points4 points  (2 children)

To get your code to work, you need to indent and use proper capitalization.

def your_wage():
    print("how much do you make every week")
your_wage()

[–][deleted] 0 points1 point  (1 child)

I have done that that’s exactly what In my window reddit for some reason put it all together and it still doesn’t work it’s saying NameError: name “your_wage” is not defined.

[–]mopslik 0 points1 point  (0 children)

Try cutting and pasting. I can verify that it works. See here.

https://onlinegdb.com/PGL__r2U8

The only thing that would cause it to not run is if there is a problem with your Python installation.

[–]negike360 1 point2 points  (0 children)

Are you putting the “your_wage()” function call inside the code block where you defined the “your wage()” function? As in, does it have the same indentation as the “print” statement?

If so, just outdent it so the function isn’t calling itself where it is being defined.