#include<iostream>
#include<vector>
using namespace std;
int main()
{
  string s;
  int count0=0, count1=0;
  cin >> s;
  for(int i=0; i<s.size(); i++){
    if(s[i] == "0")
      count0++;
    else if(s[i] == "1")
      count1++;
  }
  int a = min(count0, count1);
  }
  cout << 2*a;
  return 0;
}
      
      