When building location-based applications, one of the most common requirements is calculating the distance between two points on Earth. While it might seem straightforward at first, accurately calculating distances on a spherical surface requires some careful consideration. In this article, I'll share how I implemented this calculation for an educational geography game, Flagle Explorer.
The primary requirements for our distance calculation were:
- Accuracy suitable for educational purposes