#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  int len, n, i, j, cow = 0;
  bool ar[1005] = {false};
  getline(cin, s);
  len = s.length();
  for (i = 0; i < len; i++) {
    if (s[i] == ' ')
      continue;
    else if (s[i] == ',')
      continue;
    else if (s[i] == '{' || s[i] == '}')
      continue;
    else {
      n = s[i] - 97;
      if (ar[n] == false) {
        cow++;
        ar[n] = true;
      }
    }
  }
  cout << cow << endl;
  return 0;
}
