Assuming mean radius of the earth R = 6371 km, write a Fortran program that
reads the latitude and logitude of two cities and outputs the arc distance
(solid arc in the fugure) and shortest distance (dashed line in the figure)
between these two cities on the world.
See also:
For example:
Latitude and logitude values of Gaziantep (Türkiye) and Lisbon (Portugal) is given by:
City | Latitude | Longitude |
Gaziantep | 37o 5' N | 32o22' E |
Lisbon | 38o44' N | 9o 9' W |
An example output of your program should be as follows:
Input latitude of the first city: 37 5 N
Input longitude of the first city: 32 22 E
Input latitude of the second city: 38 44 N
Input longitude of the second city: 9 9 W
Arc Distance = 3615.6 km
Shortest Distance = 3567.3 km
SOLUTION