Could anyone help me with one direction proof of this problem please?

Suppose that beta and gamma are ordered bases for an n-dimensional real (complex) inner product space V. Prove that if Q is an orthogonal (unitary) n by n matrix that changes gamma-coordinates into beta-coordinates, then beta is orthonormal if and only if gamma is orthonormal.