#include <bits/stdc++.h>
#pragma GCC optimize("O3")
#pragma GCC target("tune=native")
#pragma GCC target("avx")
template <class T>
bool chmax(T &a, const T &b) {
  if (a < b) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
bool chmin(T &a, const T &b) {
  if (a > b) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
T gcd(T a, T b) {
  if (a < b) std::swap(a, b);
  while (b) std::swap(a %= b, b);
  return a;
}
template <class T>
T lcm(const T a, const T b) {
  return a / gcd(a, b) * b;
}
using ll = long signed long;
using ull = long unsigned long;
using cll = long long const;
using ld = long double;
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  string s;
  cin >> s;
  ll n = s.size();
  vector<ll> imos(n + 1, 0);
  for (long long i = 0, i_len = (n); i < i_len; i++) {
    imos[i + 1] = imos[i] ^ (1LL << s[i] - 'a');
  }
  vector<ll> dp(n + 1, 0x7FFFFFFF);
  dp[0] = 0;
  vector<vector<ll>> pos(1LL << 26);
  pos[0].push_back(0);
  for (long long i = (1), i_end = (n); i <= i_end; i++) {
    for (long long j = 0, j_len = (26); j < j_len; j++) {
      ll mask = imos[i] ^ (1LL << j);
      for (ll u : pos[mask]) {
        chmin(dp[i], dp[u] + 1);
      }
    }
    pos[imos[i]].push_back(i);
  }
  cout << dp[n] << endl;
}
