#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int k = 0;
  int len = s.length();
  for (int i = 0; i < len; i++) {
    if (s[i] == 1) k++;
  }
  cout << min(len - k, k) * 2 << endl;
  return 0;
}
