// ayy
// ' lamo
#include <bits/stdc++.h>
#include <bits/extc++.h>
using namespace std;
using namespace __gnu_pbds;
typedef long long ll;
typedef long double ld; //CARE
typedef complex<ld> pt;
#define fi first
#define se second
#define pb push_back
const ld eps=1e-8;
const int inf=1e9+99;
const ll linf=1e18+99;
const int P=1e9+7;





const int N=200<<10;
char s[N];
int n,dp[N];



int ps[N];
int fi[1<<26];


int32_t main() {
	scanf("%s",s);
	n=(int)strlen(s);
	for(int i=0;i<n;i++) {
		ps[i+1]=ps[i];
		ps[i+1] ^= 1<<int(s[i]-'a');
	}
	for(int i=n;i>=0;i--) fi[ps[i]]=i+1;
	for(int i=0;i<=n;i++) {
		if(i) dp[i]=1;
		if(!ps[i]) continue;
		dp[i]=1+dp[i-1];
		for(int c=0;c<=26;c++) {
			int bit=1<<c;
			if(c==26) bit=0;
			int j=fi[ps[i] ^ bit];
			if(!j) j=inf;
			else --j;
			if(j<i) dp[i]=min(dp[i],dp[j]+1);
		}
	}
	cout<<dp[n]<<endl;
}











