LI = lambda: list(map(int, input().split()))

A, P = LI()


def main():
    ans = (3 * A + P) // 2
    print(ans)


if __name__ == "__main__":
    main() LI = lambda: list(map(int, input().split())) LI lambda: list(map(int, input().split())) list(map(int, input().split())) list map(int, input().split()) map int input().split() ().split () input split A, P = LI() A LI() LI P def main():
    ans = (3 * A + P) // 2
    print(ans) main ans = (3 * A + P) // 2 ans (3 * A + P) // 2 3 * A + P 3 * A 3 A P 2 print(ans) print ans if __name__ == "__main__":
    main() __name__ == "__main__" __name__ "__main__" main() main A, P = LI() LI() A LI = lambda: list(map(int, input().split())) lambda: list(map(int, input().split())) LI P = LI() LI() P def main():
    ans = (3 * A + P) // 2
    print(ans) def main():
    ans = (3 * A + P) // 2
    print(ans) main
LI = lambda: list(map(int, input().split()))

A, P = LI()


def main():
    ans = (3 * A + P) // 2
    print(ans)


if __name__ == "__main__":
    main()
