Did something similar for Q2. For my nested loop I did for i in range(len(grid)): for j in range(len(grid)). Forgot to index grid on inner forloop. Took 5 minutes to figure it out lol.
@rosendo3219Ай бұрын
why 'while len(q)' ? instead of just 'while q'?
@AlgorithmistАй бұрын
because I want my code to represent what I mean, and not some false-y values.