Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- n = int(input())
- tire = (n-1)//2
- tire2 = 1
- if n == 1:
- print("*")
- elif n == 2:
- print("*")
- else:
- for i in range ((n-1)//2+1):
- print("-" * tire, end = "")
- print("*", end = "")
- sreda = (n-(tire*2)-2)
- if sreda >=0:
- print("-"*sreda, end = "")
- print("*",end = "")
- print("-" * tire, end="")
- print()
- tire = tire-1
- for i in range ((n-1)//2):
- print("-"*(tire2),end = "")
- print("*",end = "")
- sreda2 = n-((tire2)*2+2)
- if sreda2>= 0:
- print("-"*sreda2,end = "")
- print("*",end = "")
- print("-" * (tire2), end="")
- print()
- sreda2 = sreda2 -1
- tire2 = tire2+1
Advertisement
Add Comment
Please, Sign In to add comment