If the weekly marginal cost function of a product is given by 23+𝑥 and if the cost is

100 at zero output. The weekly price equation is p(𝑥)=100−x
Find the production levels at which profit is maximised.

revenue = price * quantity, so r(x) = x(100-x)

profit = revenue - cost, so
dp/dx = dr/dx - dc/dx = 100-2x - (23+x) = 77-3x
dp/dx=0 at x = 77/3
so, is that a max or a min? How can you tell?