#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int c1 = 0, c0 = 0, ans = 0;
  for (long long i = 0; i < ((sizeof s) - 1); i++) {
    if (s[i] == '1') c1++;
    if (s[i] == '0') c0++;
  }
  while (c0 > 0 && c1 > 0) {
    ans += 2;
    c0--;
    c1--;
  }
  cout << ans << endl;
  return 0;
}
