To find the maximal value in a matrix of numbers, we can code 5 lines to solve the problem:
ans = matrix[0][0] for x in range(len(matrix)): for y in rang
By matrix, I assume you mean a 2d-list.
max([max(i) for i in matrix])