[<AutoOpen>]
module Program

open System

let read f = stdin.ReadLine() |> f
let reads f = stdin.ReadLine().Split() |> Array.map f

[<EntryPoint>]
let main argv =
    let [|a;b|] = reads int
    if a >= 13 then
        b
    elif 6 <= a && a <= 12 then
        b / 2
    else
        0
    |> printfn "%i"
    0