import java.util.Scanner;
import java.util.regex.*;  

public class Main {
    public static void main(String[] args) {
        String string = "H e l l o ! n o w c o d e r";
        Scanner scanner= new Scanner(System.in);
        String word = scanner.next();
        scanner.close();
        System.out.println(check(string, word));
    }

    public static int check(String str, String word) {

        //write your code here......
        word = word.toLowerCase();

        Pattern pattern = Pattern.compile(word);
        Matcher matcher = pattern.matcher(str);

        int count =0;
        while(matcher.find()){
            count +=1;
        }

        return count;
    }
}