#include <bits/stdc++.h>
using namespace std;
int vis[10001];
int main() {
  char str[10001];
  cin >> str;
  int len = strlen(str);
  int l = 0, y = 0;
  int sum = 0;
  for (int i = 0; i < len; i++) {
    if (str[i] == '0')
      l++;
    else
      y++;
  }
  printf("%d", min(l, y) * 2);
}
