#include<iostream>
#include<math.h>
#include<algorithm>
#include<stdint.h>
#include<vector>
#include<deque>
#include<stack>
#include<string>
#include<cstring>
#include<time.h>
#include<array>
#include<iomanip>
#include<list>
#include<set>
#include<unordered_map>
#include<unordered_set>
#include<random>
#include<bitset>
#include <queue>
#include <map>


using namespace std;
using ll = long long;
using ull = unsigned long long;
using uint = unsigned int;
using ldouble = long double;


//BDD,ZDD,kdtree, bdtree,bicalc, bolonoy, doloney,chinesemod,segmenttree,daikusutora, saidairyuu, 2bugurahu, heirokenshutu, topologicalsort, kyourenketuseibun


#define PRI(s) cout << s << endl
#define PRIY PRI("Yes")
#define PRIN PRI("No")


int main() {
	
	int N;
	int R;
	cin >> N >> R;
	if (N >= 10) PRI(R);
	else PRI(R + 100 * (10 - N));
	
	return 0;
}
// Integral

#include <iostream>
using namespace std;

int main() {
	int d;
	while(cin >> d) {
		int x = 0;
		long long S = 0;
		for(int i = 1; i < 600/d; i++) {
			x += d;
			S += d * (x * x);
		}
		cout << S << endl;
	}
	return 0;
}