#include int main(void) { char s[101]; int i; int cnt = 0; scanf("%s", s); i = 0; while(s[i] != '\0'){ if(s[i] == 'm' && s[i + 1] == 'i'){ i += 2; while(s[i] != '\0'){ if(s[i] == 'n'){ cnt++; break; } i++; } } i++; } printf("%d\n", cnt); return 0; }