Advertisement
MatveyL

дм.3

Apr 26th, 2017
96
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. a = int(input())
  2. for i in range(a):
  3. for j in range(a):
  4. if i % 2 == 0 and j % 2 == 0:
  5. if i == 0 or i == a-1 or j == 0 or j == a -1:
  6. print(0,end = ' ')
  7. else:
  8. print(1,end = ' ')
  9. else:
  10. print(1 , end = ' ')
  11. print()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement