import java.util.Scanner;

public class Main {

	/**
	 * problem solver
	 */
	public static class Problem {

		/**
		 * paramters
		 */
		private int a;
		private int b;

		/**
		 * constructor
		 */
		Problem() {
			a = 0;
			b = 0;
		}

		/**
		 * standard input
		 */
		void input() {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		}


		/**
		 * solver
		 */
		void solve() {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		}

	}

	public static void main(String args[]) {

		Problem p = new Problem();

		p.input();

		p.solve();
	}
} import java.util.Scanner; Scanner java.util public class Main {

	/**
	 * problem solver
	 */
	public static class Problem {

		/**
		 * paramters
		 */
		private int a;
		private int b;

		/**
		 * constructor
		 */
		Problem() {
			a = 0;
			b = 0;
		}

		/**
		 * standard input
		 */
		void input() {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		}


		/**
		 * solver
		 */
		void solve() {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		}

	}

	public static void main(String args[]) {

		Problem p = new Problem();

		p.input();

		p.solve();
	}
} Main public static void main(String args[]) {

		Problem p = new Problem();

		p.input();

		p.solve();
	} main {

		Problem p = new Problem();

		p.input();

		p.solve();
	} Problem p = new Problem(); p new Problem() p.input() p.input p p.solve() p.solve p String args[] args public static class Problem {

		/**
		 * paramters
		 */
		private int a;
		private int b;

		/**
		 * constructor
		 */
		Problem() {
			a = 0;
			b = 0;
		}

		/**
		 * standard input
		 */
		void input() {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		}


		/**
		 * solver
		 */
		void solve() {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		}

	} Problem /**
		 * paramters
		 */
		private int a; a private int b; b /**
		 * constructor
		 */
		Problem() {
			a = 0;
			b = 0;
		} Problem {
			a = 0;
			b = 0;
		} a = 0 a 0 b = 0 b 0 /**
		 * standard input
		 */
		void input() {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		} input {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) a = sc.nextInt() a sc.nextInt() sc.nextInt sc b = sc.nextInt() b sc.nextInt() sc.nextInt sc sc.close() sc.close sc /**
		 * solver
		 */
		void solve() {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		} solve {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		} int ans=0; ans 0 if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			} a >=13 a 13 {
				ans = b;
			} ans = b ans b if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			} 6 <= a && a <= 12 6 <= a 6 a a <= 12 a 12 {
				ans = b/2;
			} ans = b/2 ans b/2 b 2 {
				ans = 0;
			} ans = 0 ans 0 System.out.println(ans) System.out.println System.out System System.out ans public class Main {

	/**
	 * problem solver
	 */
	public static class Problem {

		/**
		 * paramters
		 */
		private int a;
		private int b;

		/**
		 * constructor
		 */
		Problem() {
			a = 0;
			b = 0;
		}

		/**
		 * standard input
		 */
		void input() {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		}


		/**
		 * solver
		 */
		void solve() {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		}

	}

	public static void main(String args[]) {

		Problem p = new Problem();

		p.input();

		p.solve();
	}
} public class Main {

	/**
	 * problem solver
	 */
	public static class Problem {

		/**
		 * paramters
		 */
		private int a;
		private int b;

		/**
		 * constructor
		 */
		Problem() {
			a = 0;
			b = 0;
		}

		/**
		 * standard input
		 */
		void input() {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		}


		/**
		 * solver
		 */
		void solve() {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		}

	}

	public static void main(String args[]) {

		Problem p = new Problem();

		p.input();

		p.solve();
	}
} Main
import java.util.Scanner;

public class Main {

	/**
	 * problem solver
	 */
	public static class Problem {

		/**
		 * paramters
		 */
		private int a;
		private int b;

		/**
		 * constructor
		 */
		Problem() {
			a = 0;
			b = 0;
		}

		/**
		 * standard input
		 */
		void input() {
			Scanner sc = new Scanner(System.in);
			a = sc.nextInt();
			b = sc.nextInt();
			sc.close();
		}


		/**
		 * solver
		 */
		void solve() {
			int ans=0;
			if (a >=13) {
				ans = b;
			} else if (6 <= a && a <= 12) {
				ans = b/2;
			} else {
				ans = 0;
			}
			
			System.out.println(ans);
		}

	}

	public static void main(String args[]) {

		Problem p = new Problem();

		p.input();

		p.solve();
	}
}
