using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace atcoder
{
    class ABC_128_A
    {
        static void Main()
        {

            string[] input = Console.ReadLine().Split(' ');
            int A = int.Parse(input[0]);
            int P = int.Parse(input[1]);

            P = P + A * 3;

            int PIE = P / 2;

            Console.WriteLine(PIE);

        }

    }
}