This is (more or less) cribbed from the USC contest winner's solution.
Very fast and very compact solution. Nice usage of complex to calculate distance between points and recursion.
Back to basics 6 - Column Vector
908 Solvers
Back to basics 8 - Matrix Diagonals
781 Solvers
345 Solvers
3062 Solvers
436 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!