#include <bits/stdc++.h>
using namespace std;
char s[100001];
int main() {
  cin >> s;
  int c0 = 0, c1 = 0;
  int len = strlen(s);
  for (int i = 0; i < len; i++) {
    if (s[i] == '0')
      c0++;
    else if (s[i] == '1')
      c1++;
  }
  cout << min(c0, c1) * 2 << endl;
}
