#include <iostream>
using namespace std;
int cnt[2];

int main() {
  string s;

  cin >> s;

  for ( int i = 0; i < s.length(); i++ ) {
    cnt[s[i]-'0']++;
  }
  cout << min(cnt[0],cnt[1])*2 << endl;
  return 0;
}
