#include <iostream>

using namespace std;

int main()
{
    long long n, m;
    cin >> n >> m;
    if (m % 2 == 0)
        cout << ((m-2) / 2) * 5 + 6 << endl;
    else
        cout << (m / 2) * 5 + 3 << endl;
    return 0;
}