#include <bits/stdc++.h>
using namespace std;
int letter(set<char> s) {
  char a;
  int count = 0;
  while (a != '}') {
    cin >> a;
    s.insert(a);
  }
  set<char>::iterator itr;
  for (itr = s.begin(); itr != s.end(); itr++) {
    if (*itr != '{' && *itr != '}' && *itr != ',') count++;
  }
  return count;
}
int main() {
  set<char> m;
  cout << letter(m) << endl;
}
