This uses the Haversine formula to calculate the great-circle distance between two points.
distanceLatLng (
latitude1, longitude1 // first coordinates
latitude2, longitude2 // seconds coordinates
diameter // earth diameter (might be any unit)
)
// returns the distance in the specified unit
```
### Earth Diameter
* 2 * 6378.137 Kilometers
* 2 * 6378137 Meter
* 2 * 3963.190 Miles
Author
------
Created by Martin Kleppe ([@aemkei](http://twitter.com/aemkei)) at [Ubilabs](http://ubilabs.net/).
For more information
--------------------
See the [140byt.es](http://140byt.es) site for a showcase of entries (built itself using 140-byte entries!), and follow [@140bytes](http://twitter.com/140bytes) on Twitter.
Great job! Flawless stereometry packed into tweet.
The only one suggestion, as the assignment has very low precedence we may re-use
z
variable instead ofi