#include <bits/stdc++.h>
using namespace std;
using LL = long long;
constexpr LL LINF = 334ll << 53;
constexpr int INF = 15 << 26;
constexpr LL MOD = 1E9 + 7;
struct Problem {
  string s;
  multimap<int, int> m;
  vector<int> mask;
  Problem(string s) : s(s), mask(s.size()){};
  void solve() {
    int cnt = 0;
    for (int i = 0; i < (int)s.size(); ++i) {
      cnt ^= (1 << (s[i] - 'a'));
      m.emplace(cnt, i);
      mask[i] = cnt;
    }
    queue<pair<int, int>> Q;
    Q.emplace(-1, 0);
    while (1) {
      auto now = Q.front();
      Q.pop();
      int nowmask = now.first < 0 ? 0 : mask[now.first];
      auto lb = m.lower_bound(nowmask);
      while (lb != m.end() and lb->first == nowmask) {
        if (lb->second == (int)s.size() - 1) {
          cout << now.second + 1 << endl;
          return;
        }
        if (lb->second > now.first) {
          Q.emplace(lb->second, now.second + 1);
          lb = m.erase(lb);
        } else {
          ++lb;
        }
      }
      for (int i = 0; i < 26; ++i) {
        int newmask = nowmask ^ (1 << i);
        auto lb = m.lower_bound(newmask);
        while (lb != m.end() and lb->first == newmask) {
          if (lb->second == (int)s.size() - 1) {
            cout << now.second + 1 << endl;
            return;
          }
          if (lb->second > now.first) {
            Q.emplace(lb->second, now.second + 1);
            lb = m.erase(lb);
          } else {
            ++lb;
          }
        }
      }
    }
  }
};
int main() {
  cin.tie(0);
  ios_base::sync_with_stdio(false);
  string s;
  cin >> s;
  Problem p(s);
  p.solve();
  return 0;
}
