func readInts() -> [Int] {
    return readLine()!.split(separator: " ").map { Int($0)! }
}

func main() {
    let ab = readInts()
    let a = ab[0]
    let b = ab[1]
    
    if a >= 13 {
        print(b)
    } else if a >= 6 {
        print(b / 2)
    } else {
        print("0")
    }
}

main()
