// problem: "https://atcoder.jp/contests/abc127/tasks/abc127_a"

import java.util.Scanner;

class Main {
    public static void main (String args[]) {
        Scanner in = new Scanner(System.in);

        int a = in.nextInt();
        int b = in.nextInt();

        if(a>=13)
            System.out.print(b);

        else if(a>=6)
            System.out.print(b/2);

        else
            System.out.print(0);
    }
} import java.util.Scanner; Scanner java.util class Main {
    public static void main (String args[]) {
        Scanner in = new Scanner(System.in);

        int a = in.nextInt();
        int b = in.nextInt();

        if(a>=13)
            System.out.print(b);

        else if(a>=6)
            System.out.print(b/2);

        else
            System.out.print(0);
    }
} Main public static void main (String args[]) {
        Scanner in = new Scanner(System.in);

        int a = in.nextInt();
        int b = in.nextInt();

        if(a>=13)
            System.out.print(b);

        else if(a>=6)
            System.out.print(b/2);

        else
            System.out.print(0);
    } main {
        Scanner in = new Scanner(System.in);

        int a = in.nextInt();
        int b = in.nextInt();

        if(a>=13)
            System.out.print(b);

        else if(a>=6)
            System.out.print(b/2);

        else
            System.out.print(0);
    } Scanner in = new Scanner(System.in); in new Scanner(System.in) int a = in.nextInt(); a in.nextInt() in.nextInt in int b = in.nextInt(); b in.nextInt() in.nextInt in if(a>=13)
            System.out.print(b);

        else if(a>=6)
            System.out.print(b/2);

        else
            System.out.print(0); a>=13 a 13 System.out.print(b) System.out.print System.out System System.out b if(a>=6)
            System.out.print(b/2);

        else
            System.out.print(0); a>=6 a 6 System.out.print(b/2) System.out.print System.out System System.out b/2 b 2 System.out.print(0) System.out.print System.out System System.out 0 String args[] args
// problem: "https://atcoder.jp/contests/abc127/tasks/abc127_a"

import java.util.Scanner;

class Main {
    public static void main (String args[]) {
        Scanner in = new Scanner(System.in);

        int a = in.nextInt();
        int b = in.nextInt();

        if(a>=13)
            System.out.print(b);

        else if(a>=6)
            System.out.print(b/2);

        else
            System.out.print(0);
    }
}
