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

if a >= 13:
    price = b
elif a >= 6 and a <= 12:
    price = b/2
else:
    price = 0

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

if a >= 13:
    price = b
elif a >= 6 and a <= 12:
    price = b/2
else:
    price = 0

print(int(price))