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