#include <bits/stdc++.h>
using namespace std;
int main() {
  int n = 0;
  char ch;
  vector<bool> v(26, 0);
  while (cin >> ch) {
    cin >> ch;
    if (ch == '{' || ch == '}' || ch == ',' || ch == ' ') continue;
    ch -= 97;
    if (!v[ch]) {
      v[ch] = true;
      n++;
    }
  }
  cout << n;
}
