we have the formula of the income money for x items:
x*(330-x)
and we have the formula for the cost:
x^2+10*x+12
we want to maximize the profit
max (income - cost)
max(330*x-x^2-x^2-10*x-12)
= max(-2*x^2+320*x-12)
parabola.... max point is x=-b/2*a
=-320/-4 = 80