pp=[]
for i in range(12):
pp.append([])
for j in range(12):
pp[i].append(0)
for i in range(10):
a=input().split()
for j in range(10):
pp[i+1][j+1]=int(a[j])
When I make a list called pp, I make a size of 10x10, but why do I make it by setting a range of 12?
python
Maybe they're trying to apply a convolution filter or they're making a border to make sure they're leaving the edge of the grid.
© 2024 OneMinuteCode. All rights reserved.