Math Help - Total cost, revenue, profit

1. Total cost, revenue, profit

Hi guys,
Can you help me with my maths homework? Just find a way... Because I TOTAL do not understand what to do At least A variant

http://www.part.lt/perziura/9b806ea9...a94b930563.png

2. (a) find $\frac{dC}{dQ}$ and minimize.

(b) profit = revenue - cost

find $\frac{dP}{dQ}$ and maximize.

3. I still do not catch an idea how to calculate. Can you calculate A variant all. It will be much easer to understand.
d(TC)/dQ=0
Q(square )-20Q+80=0
D=(-20) (square )-4*1*80=80