const Main = (input) => {
	var xs = input.trim().split(' ').map(v=>parseInt(v,10));
    var piece = xs[0] * 3;
    var pie = Math.floor((piece + xs[1]) / 2);
    console.log(pie);
}
Main(require("fs").readFileSync("/dev/stdin","utf8"));