Lesson 7 simplification


I understand the answer to lesson 7 is:


What I am wondering is how come you don't define spam with parenthesis. In other words, why is:

def spam():



That would make a function called spam. The function would then generate two local variables.


I don't understand. What would those two variables mean, and how could i make it acceptable?


Use the code you said you knew was correct.


I knew it was correct by guessing it was. I just want to understand why it shouldn't be defined. I'm just confused mannnnnnn :frowning:


You want a variable, not a function.


As @cadecodes said, codecademy will not let you pass without doing the lesson as they intended. In this case, you need to declare seperate variables, not create them inside of a function! :slightly_smiling:


You don't need to define variables. You just declare them and start using them. Functions, on the other hand, must be defined before they can be used. That's because variables only hold a value, but functions do something. So you have to say what the function is supposed to do before you can use that function.


as a result, What should we do? Because I don't get it anything I did what you all say about issue but I cannot pass the chapter


Define two variables.