#include <bits/stdc++.h>
int main() {
  char moji[100000];
  int a = 0, b = 0, i;
  scanf("%s/n", moji);
  for (i = 0; moji[i] = '\0'; i++) {
    if (moji[i] == '0') {
      a++;
    }
    if (moji[i] == '1') {
      b++;
    }
  }
  if (a > b) {
    printf("%d", b * 2);
  } else {
    printf("%d", a * 2);
  }
  return 0;
}
