had already used sqrt, more efficient