Cody

Solution 1939599

Submitted on 17 Sep 2019
This solution is locked. To view this solution, you need to provide a solution of the same size or smaller.

Test Suite

Test Status Code Input and Output
1   Fail
assert(isequal(round(sphere_distance(100,10,50,-20,14)*10000)/10000,75.9097));

lat = 10 -20 long = 40 76 R = 100 d = 4.6426e+03

Assertion failed.

2   Fail
assert(isequal(round(sphere_distance(6371e3,-97.7430608,30.267153,-74.0244265,40.6081588)*10000)/10000,2426004.8394));

lat = -97.7431 -74.0244 long = 59.7328 49.3918 R = 6371000 d = 1.5056e+08

Assertion failed.

3   Fail
assert(isequal(round(sphere_distance(6371e3,-97.7430608,31.267153,-74.0244265,40.6081588)*10000)/10000,2364307.7819));

lat = -97.7431 -74.0244 long = 58.7328 49.3918 R = 6371000 d = 1.5066e+08

Assertion failed.

Suggested Problems

More from this Author57