#include <bits/stdc++.h>
using namespace std;
constexpr long long INF = 1e18;
template <class T>
inline bool CHMAX(T& a, T b) {
  if (a < b) {
    a = b;
    return true;
  }
  return false;
}
template <class T>
inline bool CHMIN(T& a, T b) {
  if (a > b) {
    a = b;
    return true;
  }
  return false;
}
long long dp[200020];
signed main() {
  string s;
  cin >> s;
  map<vector<long long>, long long> mp;
  auto v = vector<long long>(26, 0);
  for (long long i = (0); i < (long long)(s.size()); i++) {
    v[s[i] - 'a'] ^= 1;
    mp[v] = i;
  }
  auto sum = vector<vector<long long>>(s.size() + 1, vector<long long>(26, 0));
  for (long long i = (0); i < (long long)(s.size()); i++)
    for (long long j = (0); j < (long long)(26); j++)
      (sum[i + 1][j] += sum[i][j] + (s[i] - 'a' == j)) %= 2;
  for (long long i = (0); i < (long long)(200020); i++) dp[i] = INF;
  dp[0] = 0;
  for (long long i = (0); i < (long long)(s.size()); i++) {
    CHMIN(dp[i + 1], dp[i] + 1);
    vector<long long> tmp(26, 0);
    for (long long j = (0); j < (long long)(26); j++)
      ((tmp[j] -= sum[i][j]) += 2) %= 2;
    for (long long j = (0); j < (long long)(26); j++) {
      tmp[j]++;
      CHMIN(dp[mp[tmp] + 1], dp[i] + 1);
      tmp[j]--;
    }
  }
  long long flg = 1;
  for (long long i = (0); i < (long long)(26); i++)
    if (sum[s.size()][i] & 1) flg = 0;
  if (flg)
    cout << 1 << endl;
  else
    cout << dp[s.size()] << endl;
}
