a,b=map(int,input().split())

if 13<=a:
  p=int(b)
  print(p)
if 6<=a<=12:
  p=int(b//2)
  print(p)
if a<=5:
  print('0') a,b=map(int,input().split()) a map(int,input().split()) map int input().split() ().split () input split b if 13<=a:
  p=int(b)
  print(p) 13<=a 13 a p=int(b) p int(b) int b print(p) print p if 6<=a<=12:
  p=int(b//2)
  print(p) 6<=a<=12 6<=a 6 a 12 p=int(b//2) p int(b//2) int b//2 b 2 print(p) print p if a<=5:
  print('0') a<=5 a 5 print('0') print '0' a,b=map(int,input().split()) map(int,input().split()) a b=map(int,input().split()) map(int,input().split()) b p=int(b//2) int(b//2) p p=int(b) int(b) p
a,b=map(int,input().split())

if 13<=a:
  p=int(b)
  print(p)
if 6<=a<=12:
  p=int(b//2)
  print(p)
if a<=5:
  print('0')