Functions in Python are easy 📞
#python #tutorial #course
00:00:00 functions
00:01:49 arguments
00:04:28 exercise #1
00:06:12 return
00:08:27 exercise #2
00:10:08 conclusion
# ---------- EXAMPLE 1 ----------
def display_invoice(username, amount, due_date):
print(f“Hello {username}“)
print(f“Your bill of ${amount:.2f} is due: {due_date}“)
# display_invoice(“BroCode“, , “01/02“)
# display_invoice(“JoeSchmo“, , “02/03“)
# ---------- EXAMPLE 2 ----------
def create_name(first, last):
first = ()
last = ()
return first “ “ last
full_name = create_name(“spongebob“, “squarepants“)
print(full_name)