Python assign functions to variables

72 Views
Published
Python assign a function to a variable

#python #function #variable

def hello():
print("Hello")


hi = hello
hi()

# say = print
# say("Whoa! I can't believe this works! :O")

Bro Code merch store
Category
Bro Code
Tags
python assign a function to variable, python, function to variable
Be the first to comment