#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
const long long INF = 1e12;
const int inf = 1e9;
long long n;
int main() {
  string s;
  cin >> s;
  int a, b;
  for (int i = 0; i < (s.size()); i++) {
    if (s[i] == '0')
      a++;
    else
      b++;
  }
  cout << min(a, b) * 2 << endl;
  return 0;
}
