import java.util.Scanner;



public class Main {

	public static void main(String[] args) {

		Solve s= new Solve();
		s.solve();

	}
}


class Solve{


	 public void solve() {
		 Scanner sc = new Scanner(System.in) ;
		 int a = sc.nextInt();
		 int b = sc.nextInt();
		 int res = 0;
		 if(a>=13) {
			 res = b;
		 }else if(a>=6) {
			 res=b/2;
		 }

		 System.out.println(res);




		 }
} import java.util.Scanner; Scanner java.util public class Main {

	public static void main(String[] args) {

		Solve s= new Solve();
		s.solve();

	}
} Main public static void main(String[] args) {

		Solve s= new Solve();
		s.solve();

	} main {

		Solve s= new Solve();
		s.solve();

	} Solve s= new Solve(); s new Solve() s.solve() s.solve s String[] args args class Solve{


	 public void solve() {
		 Scanner sc = new Scanner(System.in) ;
		 int a = sc.nextInt();
		 int b = sc.nextInt();
		 int res = 0;
		 if(a>=13) {
			 res = b;
		 }else if(a>=6) {
			 res=b/2;
		 }

		 System.out.println(res);




		 }
} Solve public void solve() {
		 Scanner sc = new Scanner(System.in) ;
		 int a = sc.nextInt();
		 int b = sc.nextInt();
		 int res = 0;
		 if(a>=13) {
			 res = b;
		 }else if(a>=6) {
			 res=b/2;
		 }

		 System.out.println(res);




		 } solve {
		 Scanner sc = new Scanner(System.in) ;
		 int a = sc.nextInt();
		 int b = sc.nextInt();
		 int res = 0;
		 if(a>=13) {
			 res = b;
		 }else if(a>=6) {
			 res=b/2;
		 }

		 System.out.println(res);




		 } 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 res = 0; res 0 if(a>=13) {
			 res = b;
		 }else if(a>=6) {
			 res=b/2;
		 } a>=13 a 13 {
			 res = b;
		 } res = b res b if(a>=6) {
			 res=b/2;
		 } a>=6 a 6 {
			 res=b/2;
		 } res=b/2 res b/2 b 2 System.out.println(res) System.out.println System.out System System.out res public class Main {

	public static void main(String[] args) {

		Solve s= new Solve();
		s.solve();

	}
} public class Main {

	public static void main(String[] args) {

		Solve s= new Solve();
		s.solve();

	}
} Main
import java.util.Scanner;



public class Main {

	public static void main(String[] args) {

		Solve s= new Solve();
		s.solve();

	}
}


class Solve{


	 public void solve() {
		 Scanner sc = new Scanner(System.in) ;
		 int a = sc.nextInt();
		 int b = sc.nextInt();
		 int res = 0;
		 if(a>=13) {
			 res = b;
		 }else if(a>=6) {
			 res=b/2;
		 }

		 System.out.println(res);




		 }
}