#include <bits/stdc++.h>
using namespace std;
int main() {
  char S[100000], i = 0, C0 = 0, C1 = 0, an = 0;
  scanf("%s", S);
  while (S[i] != '\0') {
    if (S[i] == '0') {
      C0++;
    } else if (S[i] == '1') {
      C1++;
    }
    i++;
  }
  printf("%d", min(C0, C1) * 2);
  return 0;
}
