Skip to content

Commit 8d97a04

Browse files
committed
Final QA
1 parent 352cb4b commit 8d97a04

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

python-optional-arguments/mutable_default_bug.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ def add_item(item_name, quantity, shopping_list={}):
1818
clothes_shop_list = add_item("Shirt", 3) # Uses the shared default dict
1919
electronics_store_list = add_item("USB cable", 1) # Same shared dict!
2020

21-
print("\nclothes_shop_list:")
21+
print("clothes_shop_list:")
2222
for k, v in clothes_shop_list.items():
2323
print(f"{v}x {k}")
2424

python-optional-arguments/optional_params.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@
1313

1414

1515
def show_list(shopping_list, include_quantities=True):
16-
print()
1716
for item_name, quantity in shopping_list.items():
1817
if include_quantities:
1918
print(f"{quantity}x {item_name}")
2019
else:
2120
print(item_name)
21+
print()
2222

2323

2424
def add_item(item_name, quantity, shopping_list=None):

0 commit comments

Comments
 (0)