#include <iostream>
#include <string>
#include<algorithm>
using namespace std;

int main()
{
	string s;
	cin >> s;
	int zero=0, one=0;
	for (int i = 0; i < size(s); i++)
	{
		if (s[i] == '0') zero++;
		else one++;
	}
	cout << min(one, zero) * 2 << endl;
    return 0;
}