DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
middle value of a list in python
[lis[i] for i in range((len(lis)/2) - (1 if float(len(lis)) % 2 == 0 else 0), len(lis)/2+1)]
Source by stackoverflow.com #
PREVIOUS
NEXT
Tagged:
#middle
#list
#python
ADD COMMENT
Topic
COMMENT
Name
6+4 =
Submit