DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR TYPESCRIPT
sort list of list based on first element
lis = [[1,4,7],[3,6,9],[2,59,8]] sorted(lis, key=lambda x: x[0]) [[1, 4, 7], [2, 59, 8], [3, 6, 9]]
Source by cmdlinetips.com #
PREVIOUS
NEXT
Tagged:
#sort
#list
#list
#based
#element
ADD COMMENT
Topic
COMMENT
Name
2+6 =
Submit