import std.stdio, std.conv, std.string, std.math, std.regex, std.range, std.ascii, std.algorithm;

void main(){
	auto ip = readln.split.to!(int[]), A=ip[0], B=ip[1];

	if(A<6) writeln(0);
	else if(A<13) writeln(B/2);
	else writeln(B);
}