Let $v$ and $w$ be elements of an inner product space. Prove that $\|v + w\|^2 = \|v\|^2 + \|w\|^2$ iff $v,w$ are orthogonal.
I know that if $v,w$ are orthogonal they are linearly independent. Now if I suppose $v_1 + ...+ v_k = 0$ and $w_1 + ... +w_k = 0$
I have that:
$$0 = \langle v_1 + ... + v_k, v_i\rangle = \langle v_1,v_i\rangle + ... + \langle v_k,v_i\rangle = \langle v_i,v_i\rangle = \|v_i\|^2$$
and this is where I am stuck because it doesn't complete the proof.