const main = stdin => {
    const input = stdin.trim().split('\n')
    //ここにかく
    //文字列S
    const S = input[0].split(" ")[0];
    let result0 = [];
    let result1 = [];
    // const N = S.length;
    for (let i=0; i<S.length; i++){
        if (S[i] == 0){
        result0.push(0);
        }
        else{
        result1.push(1);
        }
    }
  
    let vanishN;
    if (result0.length<result1.length){
        vanishN = result0.length*2;
    }else{
        vanishN = result1.length*2
    }
console.log(vanishN);
}
    
    
    // 標準入力
    main(require("fs").readFileSync("/dev/stdin", "utf8"))