open System

[<EntryPoint>]
let main argv =
    let inputs = stdin.ReadLine().Split(' ') |> Array.map int
    let appleCount = inputs.[0]
    let applePieceCount = inputs.[1]

    let answer = (appleCount * 3 + applePieceCount) / 2

    printfn "%d" answer

    0 // return an integer exit code
