#include <bits/stdc++.h>
using namespace std;
int zero, one;
int main() {
  char ch[1000];
  scanf("%s", &ch);
  int len = strlen(ch);
  for (int i = 0; i < len; i++) {
    if (ch[i] == '0')
      ++zero;
    else if (ch[i] == '1')
      ++one;
  }
  printf("%d\n", min(zero, one) * 2);
}
