A,B = list(map(int,input().split()))

 

if A >= 13:

  print(B)

elif 6<=A<=12:

  print((B//2))

else:

  print("0")
#! python3

#  solve127A.py



age,cost = list(map(int,input().split()))



if age <= 5:

    cost = 0

elif 6 <= age <= 12:

    cost = cost//2

elif 7 <= age:

    cost = cost



print(cost)
A, B = list(map(int, input().split()))
if A >= 13:
    print(B)
elif 6 <= A <= 12:
    print((B // 2))
else:
    print("0")

#! python3
#  solve127A.py
age, cost = list(map(int, input().split()))
if age <= 5:
    cost = 0
elif 6 <= age <= 12:
    cost = cost // 2
elif 7 <= age:
    cost = cost
print(cost)

-A, B = list(map(int, input().split())) -if A >= 13: -    print(B) -elif 6 <= A <= 12: -    print((B // 2)) -else: -    print("0") +#! python3 +#  solve127A.py +age, cost = list(map(int, input().split())) +if age <= 5: +    cost = 0 +elif 6 <= age <= 12: +    cost = cost // 2 +elif 7 <= age: +    cost = cost +print(cost)