Python list[::-1]

1 개요[ | ]

Python list[::-1]
lst = ['Apple', 'Banana', 'Orange', 'Mango']
print(lst[::-1])
# ['Mango', 'Orange', 'Banana', 'Apple']
a = [0, 1, 2, 3, 4]
print(a[::-1])
# [4, 3, 2, 1, 0]

2 같이 보기[ | ]

문서 댓글 ({{ doc_comments.length }})
{{ comment.name }} {{ comment.created | snstime }}