#include <stdio.h>
#include <ctype.h>
#include <string.h>
int main() {
    char str[200];
    int count = 0;
    int isDigitOnly = 1;
    fgets(str, sizeof(str), stdin) ;
    str[strcspn(str,"\n")] = '\0';
    for(int i=0; str[i])) {
        if (!isdigit(str[i])) {
            isDigitOnly = 0;
            break;
        }
    }
    if (isDigitOnly) {
        printf("Invalid input") ;
        return 0;
    }
    for (int i = 0; str[i] !='\0'; i++) {
        if (isalpha(str[i])) {
            count++;
        }
    }
    printf("%d",count);
    return 0;
}