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