#include<iostream>
#include<vector>
#include<string>
#include<algorithm>
using namespace std;

int main(){
 std::string a;
 cin >> a;
 size_t size = str.length();
 int i = size;
 int c = 0,d = 0;
 for (int j=0;j<i;++j)
 {
   if(a[j]==0) ++c;
   else ++d;
 }
 int min = min(c,d);
 cout << min*2 << endl;
}