n,k=tuple(map(int,input().split()))
if n >= 13:
  print(k)
elif 6 <= n <= 12:
  print(k//2)
elif n <= 5:
  print(0) n,k=tuple(map(int,input().split())) n tuple(map(int,input().split())) tuple map(int,input().split()) map int input().split() ().split () input split k if n >= 13:
  print(k)
elif 6 <= n <= 12:
  print(k//2)
elif n <= 5:
  print(0) n >= 13 n 13 print(k) print k elif 6 <= n <= 12:
  print(k//2) 6 <= n <= 12 6 <= n 6 n 12 print(k//2) print k//2 k 2 elif n <= 5:
  print(0) n <= 5 n 5 print(0) print 0 n,k=tuple(map(int,input().split())) tuple(map(int,input().split())) n k=tuple(map(int,input().split())) tuple(map(int,input().split())) k
n,k=tuple(map(int,input().split()))
if n >= 13:
  print(k)
elif 6 <= n <= 12:
  print(k//2)
elif n <= 5:
  print(0)
