let main = (input) => {
	let a = Number.parseInt(input[0])
	let p = Number.parseInt(input[1])
    let result = ((a*3) + p) / 2
    console.log(Math.floor(result))
}

main(require('fs').readFileSync('/dev/stdin', 'UTF-8'))