#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1000000007;
const long long INF = 9999999999999999;
using ll = long long;
int main(){
  cin>>A>>P;
  cout << (3*A+P)/2 << endl;
  return 0;
}