Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import copy
- a,b = map(int,input().split())
- A = [0 for i in range(b)]
- B =[]
- for i in range(a):
- for j in range(b):
- if (j + i) % 2 == 1:
- A[j] = 1
- else:
- A[j] = 0
- p = copy.deepcopy(A)
- B.append(p)
- for i in range(a):
- for j in range(b):
- print(B[i][j], end = ' ')
- print()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement