star pattern
k = 3 for i in range ( 1 , 9 ): if i % 2 != 0 : print ( " " * k + "*" * i ) k = k - 1 k = 6 m = 1 for i in range ( 1 , 5 ): for j in range ( 1 ,k - i): print (m, end = " " ) m = m + 1 print ( " \n " )