#include <bits/stdc++.h>
using namespace std;

int main(void){
	string s;
	cin >> s;
	int n[2] = {0, 0};
	for(int i = 0; i < s.size(); ++i){
		n[s[i]-'0']++;
	}
	cout << 2 * min(n[0],n[1]) << endl;
	return 0;
}