We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent cb43fbe commit 44f88f0Copy full SHA for 44f88f0
docs/cheatsheet/comprehensions.md
@@ -114,7 +114,7 @@ To use an `if-else` statement in a List Comprehension:
114
A List comprehension can be generated from a dictionary:
115
116
```python
117
->>> c = {'name': 'Pooka', 'first_name': 'Oooka'}
118
->>> ["{}:{}".format(k.upper(), v.upper()) for k, v in c.items()]
119
-['NAME:POOKA', 'FIRST_NAME:OOOKA']
+>>> c = {'name': 'Pooka', 'age': 5}
+>>> ["{}:{}".format(k.upper(), v) for k, v in c.items()]
+['NAME:Pooka', 'AGE:5']
120
```
0 commit comments