DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
Return a sorted copy of the list. Does not modify original list.
li = [1,9,2,3] li2 = sorted(li) print(li) # [1, 9, 2, 3] print(li2) # [1, 2, 3, 9]
Source by xahlee.info #
PREVIOUS
NEXT
Tagged:
#Return
#sorted
#copy
#Does
#modify
#original
ADD COMMENT
Topic
COMMENT
Name
7+3 =
Submit