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