Microeconomics Price Optimization Problem

I have an econ exam tomorrow and there are a few questions that I have difficulty solving. They all relate to finding the optimum quantity or price that a company should produce at.

The correct answers are in brackets after the question , but I am more interested in explaining how the answer was obtained.

Glyde Air Fresheners is the dominant rm in the solid room aromatizer industry, which has a total market demand given by Q = 80 - 2P. Glyde has competition from a fringe of four small rms that produce where their individual marginal costs equal the market price. The fringe rms each have total costs given by TCi = 10Qi +2Q2 . If Glyde's total costs are given by TC.G = 100 + 6QG, what price should Glyde establish for air fresheners? -

(Correct answer is 18)

If a representative rm with long-run total cost given by TC = 50 + 2q + 2q2 operates in a competitive industry where the market demand is given by QD = 1410 - 40P, the long-run equilibrium output of the industry will be:

(The correct answer is 530 units)

If labor and capital produce output according to Q = 6KL^(1/2), labor costs $12, capital costs $240, and output sells for $2, the optimal level of L is:

(The correct answer is L= 400)

I know that I should try to equate MR = MC (or mrp = me) but it does not always work (the answer I get is different from the correct answer)

Any help is greatly appreciated :)