Skip to content

Commit f1eaf6c

Browse files
committed
Add RecumbentBike class (p127)
1 parent 902cd78 commit f1eaf6c

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

bike.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,12 @@ def spares(self):
8787
return spares
8888

8989

90+
class RecumbentBike(Bicycle):
91+
92+
def default_chain(self):
93+
return '9-speed'
94+
95+
9096
if __name__ == '__main__':
9197
print Gear(
9298
chainring=52,
@@ -114,4 +120,6 @@ def spares(self):
114120
front_shock='Manitou',
115121
rear_shock='fox')
116122
print mountain_bike.size
117-
print mountain_bike.spares()
123+
# print mountain_bike.spares()
124+
125+
bent = RecumbentBike()

0 commit comments

Comments
 (0)