Question

I want to get distance of two cities having their latitude and longitude. Is there a java lib to do it? Apache common math seems to have a spherical class. Is there any one used it?

Was it helpful?

Solution

Check out this answer: Calculating distance between two points, using latitude longitude, what am I doing wrong?

Doesn't utilize a library, but the accepted answer will solve your problem.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top