input: def sierpinski_triangle(n: int):
      """ Generates the first n rows of the Sierpinski triangle using bits.
      >>> sierpinski_triangle(3)
         1 
        1 0 1 
       1 0 0 0 1 
      >>> sierpinski_triangle(4)
         1 
        1 0 1 
       1 0 0 0 1 
      1 0 0 0 0 0 1 
      """
output:     triangle = ["1"]
      for i in range(1, n):
          new_row = "1"
          for j in range(1, len(triangle[i-1])):
              new_row += str(int(triangle[i-1][j-1]) ^ int(triangle[i-1][j]))
          new_row += "1"
          triangle.append(new_row)
      
      max_width = len(triangle[-1])
      for row in triangle:
          print(" " * ((max_width - len(row)) // 2) + row)