$\displaystyle x = \frac{1}{n} \sum^{n}_{i = 1} x_{i}$

$\displaystyle x = \frac{1}{n} \sum^{n}_{i = 1} x_{i} - a + a$

$\displaystyle x = \frac{1}{n} \left( \sum^{n}_{i = 1} x_{i} - na \right) + a$ <- What the heck happened with that $\displaystyle na$ thing? The transformation from the previous step, to this one, and the next step?

$\displaystyle x = \frac{1}{n} \left[ \sum^{n}_{i = 1} x_{i} - a \right] + a$

$\displaystyle x = \frac{ \sum^{n}_{i = 1} (x_{i} - a) }{n} + a$

By the way on the x on the left hand side there should be a little bar on top, indicating average.

Thanks for any help.