import java.util.Scanner

object Main {
  def main(args: Array[String]): Unit = {
    val sc = new Scanner(System.in)
    val s = sc.next().toCharArray
    
    val one = s.count(_ == '1')
    val zero = s.count(_ == '0')
    
    println(math.min(one, zero) * 2)
  }
  
  def printArray[T](arr: Array[T]): Unit = {
    for (i <- arr.indices) {
      print(s"${arr(i)} ")
    }
    println()
  }
}