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