typedef long long ll;
const int mod=1e9+7;
using namespace std;
string s;
int main () {
    cin >> s ;
    int a,b;
    a=b=0;
    int k=s.length();
    lol(i,k){
        if(s[i]=='0')a++;
        if(s[i]=='1')b++;
    }
    cout << min(a,b)*2<< endl;
}
 
 