import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int yen = 0;
		if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		}
		System.out.println(yen);
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int yen = 0;
		if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		}
		System.out.println(yen);
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int yen = 0;
		if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		}
		System.out.println(yen);
	} main {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int yen = 0;
		if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		}
		System.out.println(yen);
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int a = sc.nextInt(); a sc.nextInt() sc.nextInt sc int b = sc.nextInt(); b sc.nextInt() sc.nextInt sc int yen = 0; yen 0 if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		} a < 6 a 6 {
			yen = 0;
		} yen = 0 yen 0 if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		} a > 5 & a < 13 a > 5 a 5 a < 13 a 13 {
			yen = b / 2;
		} yen = b / 2 yen b / 2 b 2 {
			yen = b;
		} yen = b yen b System.out.println(yen) System.out.println System.out System System.out yen String[] args args public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int yen = 0;
		if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		}
		System.out.println(yen);
	}
} public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int yen = 0;
		if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		}
		System.out.println(yen);
	}
} Main
import java.util.*;

public class Main {
	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in);
		int a = sc.nextInt();
		int b = sc.nextInt();
		int yen = 0;
		if (a < 6) {
			yen = 0;
		} else if (a > 5 & a < 13) {
			yen = b / 2;
		} else {
			yen = b;
		}
		System.out.println(yen);
	}
}