This solution is outdated. To rescore this solution, sign in.
-
1 Comment
Dale Crawford
on 7 Dec 2015
I think this works for very low numbers but as you get higher, a work around that might be faster is
n*(n+1)/2
Suggested Problems
-
Remove any row in which a NaN appears
8663 Solvers
-
484 Solvers
-
795 Solvers
-
Who is the smartest MATLAB programmer?
766 Solvers
-
Find last zero for each column
600 Solvers
More from this Author96
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!