Menu

2D Arrays - Code Quiz

1. What is printed by this code?

grid = [[4, 7, 2], [9, 1, 5], [6, 3, 8]] print(grid[2][1])
5
6
3
8

2. What is printed by this code?

seats = [['A1', 'A2', 'A3'], ['B1', 'B2', 'B3']] print(str(len(seats)) + ' ' + str(len(seats[0])))
3 2
6
2 3
2 2

Log in or sign-up to access the quiz



Don't have a login?

You can still revise this topic