#include <bits/stdc++.h>
using namespace std;
const int MAX = 100;
bool mrk[MAX];
int main() {
  char c;
  cin >> c;
  while (c != '}') {
    cin >> c;
    if (c >= 'a' && c <= 'z') mrk[c - 'a'] = 1;
  }
  int cnt = 0;
  for (int i = 0; i < MAX; i++)
    if (mrk[i] == 1) cnt++;
  cout << cnt << endl;
}
