input: Write a function to generate the first n elements of the Sierpinski triangle in Python. The function should print the Sierpinski triangle pattern for the given number of rows. If n is less than or equal to 0, the function should print an empty line.
  def sierpinski_triangle(n): 
      if n <= 0: 
          print() 
          return 
      for i in range(n): 
          print(' ' * (2**(n-i-1)), end="") 
          for j in range(2**i): 
              print('1', end=" ") 
          print() 
  
  assert sierpinski_triangle(6) is None
  assert sierpinski_triangle(0) is None
  assert sierpinski_triangle(-1) is None
output: def sierpinski_triangle(n): 
      if n <= 0: 
          print() 
          return 
      for i in range(n): 
          print(' ' * (2**(n-i-1)), end="") 
          for j in range(2**i): 
              print('1', end=" ") 
          print()