import java.util.Scanner;

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

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