#include <bits/stdc++.h>
using namespace std;
int main() {
  long long apple, pieces;
  long long pies = 0;
  cin >> apple >> pieces;
  pies = (pieces + apple * 3) / 2;
  cout << pieces;
  return 0;
}
