function Main(input) {
  a = input.split(' ')[0] * 1
  b = input.split(' ')[1] * 1
  ans = 0
  if (a >= 13) {
      ans = b 
  } else if (a >= 6) {
      ans = b / 2
  }
  console.log(ans);
}
Main(require("fs").readFileSync("/dev/stdin", "utf8"));
