"use strict";
    
const main = arg => {
    arg = arg.split("\n");
    const A = parseInt(arg[0].split(" ")[0]);
    const P = parseInt(arg[0].split(" ")[1]);
    
    console.log(((A * 3) + P) / 2);
}
main(require('fs').readFileSync('/dev/stdin', 'utf8'));