Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR TYPESCRIPT

some of elements are arrays in python

l = len(matrix[0])
print([matrix[i][i] for i in range(l)])              # [-2, -6, 7,  8]
print([matrix[l-1-i][i] for i in range(l-1,-1,-1)])  # [ 2,  5, 2, -1]
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #elements #arrays #python
ADD COMMENT
Topic
Name
8+7 =