
main = do
    [a,b] <- map read . words <$> getLine :: IO [Int]
    print $ if 13 <= a
            then b
            else if 6 <= a && 12 >= a
                then div b 2
                else 0
                