Skip to content

Commit 6850a44

Browse files
committed
desrever
1 parent 96085c1 commit 6850a44

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

‎python/02-lists.py‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,3 +127,10 @@
127127
print(data_reversed)
128128

129129

130+
########## REVERSE USING SLICING ##########
131+
132+
data = ["a", "b", "c", "d", "e", "f", "g", "h"]
133+
data[:] = data[::-1]
134+
print(data)
135+
136+

0 commit comments

Comments
 (0)