Argument vs parameter


#1

I want to piggy back on this topic and ask what the different between an argument and a parameter is? This exercise lists ‘lst’ as a parameter but most exercises use the term argument.


11/18 List manipulation in functions
#2

the guidelines say you should start a new topic, not hijack an existing one. There was a reason you got a message which ask you to confirmation if you wanted to revive this old topic.

As you can see, it took 5 days for us to find this, given it was in a cluttered topic, if you would have made a new topic, you would have gotten a reply within a day

parameter refers to function declaration, while argument refers to the value at function calls. But programmers do generally not give massive value to the exact terminology, understanding how they work is far more important.

also, there is named arguments:

def example(x=None):
    print x

example()

given we don’t provide an argument at function call, it will use None.

but as mentioned, x=None are referred to as named argument, which makes it confusing.


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.