import sys, math
from collections import defaultdict, deque, Counter
from bisect import bisect_left, bisect_right
from itertools import combinations, permutations, product
from heapq import heappush, heappop
from functools import lru_cache
input = sys.stdin.readline
rs = lambda: input().strip()
ri = lambda: int(input())
rl = lambda: list(map(int, input().split()))
mod = 1000000007
sys.setrecursionlimit(1000000)

A, B = rl()

if A >= 13:
	print(B)
elif A >= 6:
	print(B//2)
else:
	print(0) import sys, math sys math from collections import defaultdict, deque, Counter from bisect import bisect_left, bisect_right from itertools import combinations, permutations, product from heapq import heappush, heappop from functools import lru_cache input = sys.stdin.readline input sys.stdin.readline sys.stdin sys stdin readline rs = lambda: input().strip() rs lambda: input().strip() input().strip() ().strip () input strip ri = lambda: int(input()) ri lambda: int(input()) int(input()) int input() input rl = lambda: list(map(int, input().split())) rl lambda: list(map(int, input().split())) list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split mod = 1000000007 mod 1000000007 sys.setrecursionlimit(1000000) sys.setrecursionlimit sys setrecursionlimit 1000000 A, B = rl() A rl() rl B if A >= 13:
	print(B)
elif A >= 6:
	print(B//2)
else:
	print(0) A >= 13 A 13 print(B) print B elif A >= 6:
	print(B//2) A >= 6 A 6 print(B//2) print B//2 B 2 print(0) print 0 mod = 1000000007 1000000007 mod input = sys.stdin.readline sys.stdin.readline input B = rl() rl() B A, B = rl() rl() A rs = lambda: input().strip() lambda: input().strip() rs ri = lambda: int(input()) lambda: int(input()) ri rl = lambda: list(map(int, input().split())) lambda: list(map(int, input().split())) rl
import sys, math
from collections import defaultdict, deque, Counter
from bisect import bisect_left, bisect_right
from itertools import combinations, permutations, product
from heapq import heappush, heappop
from functools import lru_cache
input = sys.stdin.readline
rs = lambda: input().strip()
ri = lambda: int(input())
rl = lambda: list(map(int, input().split()))
mod = 1000000007
sys.setrecursionlimit(1000000)

A, B = rl()

if A >= 13:
	print(B)
elif A >= 6:
	print(B//2)
else:
	print(0)
