#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int n = s.size();
  int isOdd[n + 1];
  fill_n(isOdd, n + 1, 0);
  int dp[n + 1];
  fill_n(dp, n + 1, 1000000);
  dp[0] = 0;
  map<int, int> bintoid;
  int vec[n + 1];
  fill_n(vec, n + 1, -1);
  vec[0] = 0;
  bintoid[0] = 0;
  int nid = 1;
  for (int i = 0; i < (int)(n); i++) {
    int c = s[i] - 'a';
    isOdd[i + 1] = (isOdd[i] ^ (1 << c));
    for (int j = 0; j < (int)(26); j++) {
      int k = isOdd[i + 1] ^ (1 << j);
      if (bintoid.find(k) == bintoid.end()) continue;
      int id = bintoid[k];
      dp[i + 1] = min(dp[i + 1], dp[vec[id]] + 1);
    }
    if (bintoid.find(isOdd[i + 1]) != bintoid.end()) {
      dp[i + 1] = min(dp[i + 1], dp[vec[bintoid[isOdd[i + 1]]]] + 1);
    }
    if (bintoid.find(isOdd[i + 1]) == bintoid.end()) {
      bintoid[isOdd[i + 1]] = nid++;
    }
    if (vec[bintoid[isOdd[i + 1]]] < 0) vec[bintoid[isOdd[i + 1]]] = (i + 1);
  }
  cout << dp[n] << endl;
  return 0;
}
