Skip to content

Instantly share code, notes, and snippets.

@tamert
Created October 6, 2019 10:04
Show Gist options
  • Save tamert/693d02d9afb3139b977cfea6d62f3584 to your computer and use it in GitHub Desktop.
Save tamert/693d02d9afb3139b977cfea6d62f3584 to your computer and use it in GitHub Desktop.
# * operator
def order_pizza(*pizzas):
for i in range(len(pizzas)):
print(i, pizzas[i])
order_pizza('Bora', 'Tolga', 'Sevil')
# * operator
def frameworks(*lovers):
for i in range(len(lovers)):
print(i, lovers[i]['name'])
we_love = {
"name": "React",
}
you_love = {
"name": "Vue",
}
frameworks(we_love, you_love)
# ** operator
def print_list_of(**books_and_articles):
for kw in books_and_articles:
print(kw, ":", books_and_articles[kw])
print_list_of(
python="What is webpack?",
python_essentials="What is Python Object Model?",
javascript='What is Object?')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment