#include <bits/stdc++.h>
#pragma GCC target("avx2")
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")
long x[200001];
int dp[200001];
int main() {
  std::string s;
  std::cin >> s;
  int n = s.size();
  x[0] = 0;
  for (int i = 1; i <= n; i++) {
    char c = s[i - 1];
    int d = c - 'a';
    x[i] = 1l << d;
    x[i] ^= x[i - 1];
    int v = x[i];
  }
  dp[0] = 0;
  for (int i = 1; i <= n; i++) {
    int min = 200001;
    for (int j = 0; j < i; j++) {
      int xij = x[i] ^ x[j];
      if ((xij & -xij) == xij) {
        min = std::min(min, dp[j]);
      }
    }
    dp[i] = min + 1;
    int v = dp[i];
  }
  int a = dp[n];
  std::cout << a << std::endl;
  return 0;
}
