a, b = map(int, input().split())
if a >= 13:
    fee = b
elif 6 <= a <= 12:
    fee = b // 2
else:
    fee = 0

print(fee) a, b = map(int, input().split()) a map(int, input().split()) map int input().split() ().split () input split b if a >= 13:
    fee = b
elif 6 <= a <= 12:
    fee = b // 2
else:
    fee = 0 a >= 13 a 13 fee = b fee b elif 6 <= a <= 12:
    fee = b // 2 6 <= a <= 12 6 <= a 6 a 12 fee = b // 2 fee b // 2 b 2 fee = 0 fee 0 print(fee) print fee fee = b // 2 b // 2 fee b = map(int, input().split()) map(int, input().split()) b fee = 0 0 fee a, b = map(int, input().split()) map(int, input().split()) a fee = b b fee
a, b = map(int, input().split())
if a >= 13:
    fee = b
elif 6 <= a <= 12:
    fee = b // 2
else:
    fee = 0

print(fee)