#include <stdio.h>

int main() {
    float a;
    char b;
    scanf("%f %c", &a, &b);
    if (a <= 1 && b == 'y')
        printf("%d", 25);
    else if (a <= 1 && b == 'n')
        printf("%d", 20);
    else if (a > 1 && b == 'y')
        printf("%d", (int)(a - 1 + 0.9) + 25);
    else if (a > 1 && b == 'n')
        printf("%d", (int)(a - 1 + 0.9) + 20);
    return 0;
}