import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner sc=new Scanner(System.in); double kg=sc.nextDouble(); char b=sc.next().charAt(0); int price=0; if(kg<=1){ price=20; }else{ price=20+(int)(kg-0.1); } if(b=='y'){ System.out.println(price+5); }else{ System.out.println(price); } } }