#include <bits/stdc++.h>
using namespace std;
#define MOD 1000000007
typedef long long ll;

int main(){
    int S;
    cin >> S;
    int cnt = 0;
    for(int i=0;i<S.size();i++){
        if(S.at(i) == '0') cnt = cnt + 1;
    }
    cout << 2 * min(cnt,S.size() - cnt) << endl;
}