import java.io.*;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		}
	}

} import java.io.*; io.* java public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		}
	}

} Main public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		}
	} main {
		// TODO 自動生成されたメソッド・スタブ
		try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		}
	} try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		} catch (IOException e) {
			System.out.print(e);
		} IOException e {
			System.out.print(e);
		} System.out.print(e) System.out.print System.out System System.out e {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} BufferedReader in = new BufferedReader(new InputStreamReader(System.in)); in new BufferedReader(new InputStreamReader(System.in)) String line = new String(in.readLine()); line new String(in.readLine()) String[] input = line.split(" ", 0); input line.split(" ", 0) line.split line " " 0 int age = Integer.parseInt(input[0].trim()); age Integer.parseInt(input[0].trim()) Integer.parseInt Integer input[0].trim() input[0].trim input[0] input 0 int price = Integer.parseInt(input[1].trim()); price Integer.parseInt(input[1].trim()) Integer.parseInt Integer input[1].trim() input[1].trim input[1] input 1 if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			} age <= 5 age 5 {
				System.out.print("0");
			} System.out.print("0") System.out.print System.out System System.out "0" if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			} age <= 12 age 12 {
				System.out.print(price / 2);
			} System.out.print(price / 2) System.out.print System.out System System.out price / 2 price 2 {
				System.out.print(price);
			} System.out.print(price) System.out.print System.out System System.out price String[] args args public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		}
	}

} public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		}
	}

} Main
import java.io.*;

public class Main {

	public static void main(String[] args) {
		// TODO 自動生成されたメソッド・スタブ
		try {
		BufferedReader in = new BufferedReader(new InputStreamReader(System.in));
		String line = new String(in.readLine());
		String[] input = line.split(" ", 0);
		int age = Integer.parseInt(input[0].trim());
		int price = Integer.parseInt(input[1].trim());
		//System.out.println("入力値は、" + age + "と" + price);
		
			if(age <= 5) {
				System.out.print("0");
			}else if(age <= 12) {
				System.out.print(price / 2);
			}else {
				System.out.print(price);
			}
		} catch (IOException e) {
			System.out.print(e);
		}
	}

}
