#include <bits/stdc++.h>
using ll = long long;
using namespace std;
const int INF = 1e8;
const ll LINF = 1e15;
int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  int a, p;
  cin >> a >> p;
  cout << (int)((a * 3 + p) / 2) << endl;
}
