$stdin.readlines.map(&:to_i).each do |weight|
  result = []

  weight.to_s(2).chars.each_with_index do |bin_num, index|
    result << 2 ** index if bin_num == '1'
  end

  print "#{result.join(' ')}\n"
end