object Main extends App {
  val sc = new java.util.Scanner(System.in)
  val s = sc.next.split("").map(_.toInt)
  val num1 = s.sum
  val num2 = s.size - num1

  val ans = math.min(num1, num2) * 2
  println(ans)

}