@@ -4229,9 +4229,8 @@ pairs within braces, for example: ``{'jack': 4098, 'sjoerd': 4127}`` or ``{4098:
4229
4229
value) `` pairs. Order comparisons ('<', '<=', '>=', '>') raise
4230
4230
:exc: `TypeError `.
4231
4231
4232
- Dict preserves insertion order. Note that updating key doesn't affects the
4233
- order. On the other hand, keys added after deletion are inserted to the
4234
- last. ::
4232
+ Dictionaries preserve insertion order. Note that updating a key does not
4233
+ affect the order. Keys added after deletion are inserted at the end. ::
4235
4234
4236
4235
>>> d = {"one": 1, "two": 2, "three": 3, "four": 4}
4237
4236
>>> d
@@ -4249,7 +4248,7 @@ pairs within braces, for example: ``{'jack': 4098, 'sjoerd': 4127}`` or ``{4098:
4249
4248
{'one': 42, 'three': 3, 'four': 4, 'two': None}
4250
4249
4251
4250
.. versionchanged :: 3.7
4252
- Dict order is guaranteed to be insertion order. This behavior was
4251
+ Dictionary order is guaranteed to be insertion order. This behavior was
4253
4252
implementation detail of CPython from 3.6.
4254
4253
4255
4254
.. seealso ::
@@ -4288,7 +4287,7 @@ support membership tests:
4288
4287
a :exc: `RuntimeError ` or fail to iterate over all entries.
4289
4288
4290
4289
.. versionchanged :: 3.7
4291
- Dict order is guaranteed to be insertion order.
4290
+ Dictionary order is guaranteed to be insertion order.
4292
4291
4293
4292
.. describe :: x in dictview
4294
4293
@@ -4702,3 +4701,4 @@ types, where they are relevant. Some of these are not reported by the
4702
4701
4703
4702
.. [5 ] To format only a tuple you should therefore provide a singleton tuple whose only
4704
4703
element is the tuple to be formatted.
4704
+
0 commit comments