8000 [3.14] gh-134789: Document del s[i] operation for mutable sequences (… · python/cpython@0ea41f8 · GitHub
[go: up one dir, main page]

Skip to content

Commit 0ea41f8

Browse files
[3.14] gh-134789: Document del s[i] operation for mutable sequences (GH-134804) (#134808)
gh-134789: Document del s[i] operation for mutable sequences (GH-134804) [main] Update stdtypes.rst - Added explicit mention of `del s[i]` (item deletion by index) to the Mutable Sequence Types section. - Clarified that this operation removes the item at the specified index from the sequence. - Addresses issue GH-134789. (cherry picked from commit 967f361) Co-authored-by: Rishabh Singh <67859818+rishabh11336@users.noreply.github.com>
1 parent cc81b63 commit 0ea41f8

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Doc/library/stdtypes.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1214,6 +1214,8 @@ accepts integers that meet the value restriction ``0 <= x <= 255``).
12141214
| ``s[i] = x`` | item *i* of *s* is replaced by | |
12151215
| | *x* | |
12161216
+------------------------------+--------------------------------+---------------------+
1217+
| ``del s[i]`` | removes item *i* of *s* | |
1218+
+------------------------------+--------------------------------+---------------------+
12171219
| ``s[i:j] = t`` | slice of *s* from *i* to *j* | |
12181220
| | is replaced by the contents of | |
12191221
| | the iterable *t* | |

0 commit comments

Comments
 (0)
0