#include <bits/stdc++.h>
using namespace std;
char c[300001];
int can[100];
bitset<30> a[300001], x;
int main() {
  scanf("%s", c + 1);
  a[0].reset();
  int n = strlen(c + 1);
  for (register int i = 1; i <= n; i++) {
    a[i] = a[i - 1];
    if (a[i][c[i] - 'a'])
      a[i][c[i] - 'a'] = 0;
    else
      a[i][c[i] - 'a'] = 1;
  }
  for (register int i = 0; i < 26; i++) {
    int num = 0, r;
    for (register int j = 1; j <= n; j++)
      if ((c[j] - 'a') == i) num++, r = j;
    if (num & 1) can[i] = 1;
  }
  int la = 0, ans = 0;
  while (la != n) {
    int k = la;
    for (register int i = la + 1; i <= n; i++) {
      x = a[i] ^ a[la];
      if (x.count() == 1) {
        for (register int j = 0; j < 26; j++)
          if (x[j] && can[j]) {
            ans++;
            la = i;
            can[j] = 0;
            break;
          }
      } else if (x.count() == 0) {
        la = i;
        break;
      }
    }
  ext:
    if (k == la) {
      la++;
      can[c[la] - 'a'] ^= 1;
      ans++;
    }
  }
  if (ans == 0)
    cout << 1 << endl;
  else
    cout << ans << endl;
  return 0;
}
