print(input().replace("-", "").count("min"))