import scala.io.Source.stdin

object Main {
  val w = List(1,2,4,8,16,32,64,128,256,512)
  def main(args:Array[String]) =
    println(stdin.getLines.map(_.toInt).map { i=>w.filter(y=>(y & i)>0).mkString(" ") }.mkString("\n"))
}