Python Functions, Packing, and Unpacking Getting Info In and Out of Functions Functions with Arguments and Returns

Jorge Grajeda
Jorge Grajeda
1,068 Points

I feel like I am missing something to completing this challenge I cannot figure what it is though

Can somebody walk me threw a little bit how to solve this problem because I reviewed the video and I feel lost.

creating_functions.py
def hello_student(name):
    return("Hello " + name)

print(hello_student)

1 Answer

Robert Peters
Robert Peters
3,580 Points

Hi. You got the first part right, it's just the calling of the function at the end. It says to call the function, which would be:

hello_student()

But it takes an argument 'name' so it would be:

hello_student("Rob")

It then says to store that within a variable 'hello', so it would be:

hello = hello_student("Rob")

Hope this helps! The full code would be:

def hello_student(name):
    return 'Hello ' + name

hello = hello_student("Rob")