#include void chmax(int *a, int b) { if (*a < b) *a = b; } int main() { char S[1000001]; scanf("%s", S); int i, ans = 0, tmp = 0, flag = 0; for (i = 0; S[i] != 0; i++) { switch (flag) { case 0: if (S[i] == 'y') flag++; else { tmp = 0; flag = 0; } break; case 1: if (S[i] == 'u') flag++; else { tmp = 0; flag = 0; } break; case 2: if (S[i] == 'k') flag++; else { tmp = 0; flag = 0; } break; case 3: if (S[i] == 'i') flag++; else { tmp = 0; flag = 0; } break; case 4: if (S[i] == 'c') flag++; else { tmp = 0; flag = 0; } break; case 5: if (S[i] == 'o') flag++; else { tmp = 0; flag = 0; } break; case 6: if (S[i] == 'd') flag++; else { tmp = 0; flag = 0; } break; case 7: if (S[i] == 'e') flag++; else { tmp = 0; flag = 0; } break; case 8: if (S[i] == 'r') { tmp++; chmax(&ans, tmp); } else tmp = 0; flag = 0; break; } } printf("%d\n", ans); fflush(stdout); return 0; }