#include<stdio.h>

int main()
{
	int d, i;
	while (scanf("%d", &d) != NULL)
	{
		if (d == 0)break;
		int tmp = d, total = 0;
		for (i = tmp; i < 600; i += d)
		{
			total = total + i*i*d;
		}
		printf("%d\n", total);
	}
	return 0;
}