mirror of
https://github.com/cooperhammond/irs.git
synced 2025-02-02 08:10:59 +00:00
9 lines
213 B
Python
9 lines
213 B
Python
def center(lst):
|
|
length = len(lst)
|
|
center = -1
|
|
for num in range(0, length):
|
|
if not (num % 2):
|
|
center += 1
|
|
return lst[center]
|
|
|
|
print (center(center([1, 2, [1, 2, 3], 4, 5]))) |