input: 
  def sierpinski_triangle(n): 
      """Generate the first n elements of the Sierpinski triangle by printing a binary representation.
      
      Example:
      >>> sierpinski_triangle(4)
          1 
         1 1 
        1 0 1 
       1 1 1 1 
      """
      for i in range(n): 
          print(' ' * (n - i - 1), end="") 
          for j in range(2**i): 
              if j & (j + 1) == 0: 
                  print('1', end=" ") 
              else: 
                  print('0', end=" ") 
          print()
  
output:     for i in range(n):
          print(' ' * (n - i - 1), end="")
          for j in range(2**i):
              if j & (j + 1) == 0:
                  print('1', end=" ")
              else:
                  print('0', end=" ")
          print()