Created
February 4, 2020 09:38
-
-
Save santosadrian/05b5d3dcdc9e567f5546518f12e55953 to your computer and use it in GitHub Desktop.
Example 19
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def cheese_and_crackers(cheese_count, boxes_of_crackers): | |
print(f"You have {cheese_count} cheeses!") | |
print(f"You have {boxes_of_crackers} boxes of crackers!") | |
print("Man that's enough for a party!") | |
print("Get a blanket. \n") | |
print("We can just give the function numbers directly:") | |
cheese_and_crackers(20, 30) | |
print("OR, we can use variables from our script:") | |
amount_of_cheese = 10 | |
amount_of_crackers = 50 | |
cheese_and_crackers(amount_of_cheese, amount_of_crackers) | |
print("We can even do math inside too:") | |
cheese_and_crackers(10 + 20, 5 + 6) | |
print("And we can combine the two, variables and math:") | |
cheese_and_crackers(amount_of_cheese + 100, amount_of_crackers + 77) | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment