I am new to SML-coding and need help to code a function. The function "nearest(w, m)" should calculate the distance to the coordinate
in the list m which is closest to the coordinate w. If the list is empty then use exception Empty.
We have been given a sml-file that can calculate the distance.
sorry, I didn't mean that you should do my homework for me - as I wont learn anything from that .
I have coded the following, but can't continue from there. And I know that I should use "Real.min" to get to the nearest distance, but again, don't know how to.