Is a complete code always optimal?
No. If I have three symbols with probabilities A = 0.5, B = 0.25 and C = 0.25 then A=0, B=10, C=11 is complete and optimal. B=0, A=10, C=11 is complete but absolutely not optimal. 

An optimal code on the other hand must be complete, because otherwise you can shorten the encoding of some symbol.