Let n be an integer greater than one. Prove that n is a perfect square i.f.f. n's prime factorization, n=p_1*p_2*...*p_r, has only even exponents.

So I think I'm doing an analytical proof that establishes a biconditional with reference to the above statement.

By definition a perfect square is a number, n, such that n=m^2x=(m^x)^2 and after substituting,

I need to show that each exponent on a prime is even and I'm not entirely sure how to do this at the moment.

I don't think I can just go straight to

since I would need some kind of condition that requires each exponent to be an integer (maybe?) and that 2 divides any a with no remainder?

The proof of the other direction, from each prime factor having even exponents to n being a perfect square, is done already.