View Problem

Find the distance between two points

ExpandDiskEdit
fsharp
let distance' = distance (34, 78) (67, -45)
printfn "%3.2f" distance'
ExpandDiskEdit
cpp C++/CLI .NET 2.0
Point p1 = {34, 78}, p2 = {67, -45};
double distance = ::distance(p1, p2);
Console::WriteLine("{0,3:F2}", distance);

Submit a new solution for fsharp or cpp
There are 24 other solutions in additional languages (clojure, csharp, erlang, fantom ...)