#include <bits/stdc++.h>
using namespace std;

int main() {
  int c0 = 0,c1 = 0;
  string s;
  cin >> s;
  for(int i = 0;i < s.size();i++){
    if(s.at(i) == '0') c0++;
    else c1++;
  }
  cout << min(c0,c1)*2 << endl;
}
