#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
int be[30], till[200100], dp[200100];
map<int, int> m1;
int sol(int x) {
  if (dp[x] != -1) return dp[x];
  int res = mod;
  for (int i = 0; i <= 26; i++) {
    int nxt = m1[till[x - 1] ^ be[i]] + 1;
    if (nxt > x) res = min(res, sol(nxt) + 1);
  }
  return dp[x] = res;
}
int main() {
  string s;
  for (int i = 0; i < 26; i++) {
    be[i + 1] = (1 << i);
  }
  cin >> s;
  int n = s.size();
  for (int i = 0; i < n; i++) {
    int p = s[i] - 'a';
    dp[i + 1] = -1;
    till[i + 1] = till[i] ^ (1 << p);
    m1[till[i + 1]] = i + 1;
  }
  dp[n + 1] = 0;
  cout << sol(1);
}
