#include <bits/stdc++.h>
using namespace std;
string S;
int N = S.length();
int main() {
  cin >> S;
  int zero = 0;
  int one = 0;
  for (int i = 0; i < N; i++) {
    if (S[i] == '0')
      zero++;
    else
      one++;
  }
  cout << min(zero, one) * 2 << endl;
  return 0;
}
