Compare 2d points for distance from origin in java hackerrank. The simplest solution ...