From d122224f6ebc4fd0593cc88ae6dc06c54b67cbe9 Mon Sep 17 00:00:00 2001 From: cheeks <134818917+leftovertoast@users.noreply.github.com> Date: Fri, 21 Feb 2025 14:23:39 +0000 Subject: [PATCH] Completed 8-14 Cars --- Chapter_08/8-14_cars.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 Chapter_08/8-14_cars.py diff --git a/Chapter_08/8-14_cars.py b/Chapter_08/8-14_cars.py new file mode 100644 index 0000000..2fef877 --- /dev/null +++ b/Chapter_08/8-14_cars.py @@ -0,0 +1,15 @@ +# Exercise 8-14 Cars +# Learning Objective: Make a function that contains a dictionary and allows arbitrary numbers of arguments +# with two expected arguments of Manufacturer and Model Name + + +def make_car(make, model, **car_info): + car_info['Manufacturer'] = make + car_info['Model'] = model + return car_info + +my_car = make_car('nissan', 'z', color='red', transmission='manual', rubber_floor_mats=True) + +print(my_car) + +