Skip to content

Commit 6e7c281

Browse files
committed
Add variable defs to cater-waiter introduction. (exercism#3775)
1 parent c54b7b9 commit 6e7c281

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

exercises/concept/cater-waiter/.docs/introduction.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -126,6 +126,27 @@ There is no operator equivalent:
126126

127127

128128
```python
129+
# Both mammals and additional_animals are lists.
130+
>>> mammals = ['squirrel','dog','cat','cow', 'tiger', 'elephant']
131+
>>> additional_animals = ['pangolin', 'panda', 'parrot',
132+
'lemur', 'tiger', 'pangolin']
133+
134+
# Animals is a dict.
135+
>>> animals = {'chicken': 'white',
136+
'sparrow': 'grey',
137+
'eagle': 'brown and white',
138+
'albatross': 'grey and white',
139+
'crow': 'black',
140+
'elephant': 'grey',
141+
'dog': 'rust',
142+
'cow': 'black and white',
143+
'tiger': 'orange and black',
144+
'cat': 'grey',
145+
'squirrel': 'black'}
146+
147+
# Birds is a set.
148+
>>> birds = {'crow','sparrow','eagle','chicken', 'albatross'}
149+
129150
# Mammals and birds don't share any elements.
130151
>>> birds.isdisjoint(mammals)
131152
True

0 commit comments

Comments
 (0)