Finding Square Root through Prime Factorisation