#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int red = 0;
  int blue = 0;
  for (int i = 0; i < s.size(); i++) {
    if (s[i] == 0)
      red++;
    else
      blue++;
  }
  cout << min(red, blue) * 2 << endl;
}
