#include <bits/stdc++.h>
using namespace std;
const int inf = 1000000007;
const long long linf = 1ll * inf * inf;
const int N = 200000 + 7;
const int M = 31;
const int multipleTest = 0;
string s;
int n;
int dp[N];
int sub[1 << 26];
vector<int> need;
int calc() {
  memset(sub, 0, sizeof(sub));
  for (int i = (1), _b = (n + 1); i < _b; ++i) {
    int c = s[i - 1] - 'a';
    dp[i] = dp[i - 1] ^ (1 << c);
    sub[dp[i]] = i;
  }
  need.push_back(0);
  for (int i = (0), _b = (26); i < _b; ++i) need.push_back(1 << i);
  int res = 0;
  int preMask = 0;
  int i = 1;
  while (i <= n) {
    int mx = i;
    for (int mask : need) {
      int cur = mask ^ preMask;
      if (sub[cur] >= i) mx = max(mx, sub[cur]);
    }
    preMask = dp[mx];
    i = mx + 1;
    ++res;
  }
  return res;
}
void solve() {
  cin >> s;
  n = (int)(s).size();
  int res = calc();
  reverse(s.begin(), s.end());
  res = min(res, calc());
  cout << res;
}
int main() {
  int Test = 1;
  if (multipleTest) {
    cin >> Test;
  }
  for (int i = 0; i < Test; ++i) {
    solve();
  }
}
