Question #238

What is the type of return_hello in the code snippet below?
def return_hello():
    return "hello!"

print(type(return_hello))

In the code snippet, return_hello is a function whilst return_hello() is a string. Functions are also objects in Python! (dbader.org/blog/python-first-class-functions#:~:text=Pyth...)


Comment on Disqus:

Comment on Twitter:

Question difficulty: 🔵🔵🔵🔵🔵