Problem 308. Matrix with different incremental runs
Solution Stats
Problem Comments
Solution Comments
-
1 Comment
Julio
on 12 Feb 2012
yes of course. Leading solution:
function b = matInc(a)
[b aa] = ndgrid(1:max(a), a);
b(b > aa) = 0;
end
regards,
Problem Recent Solvers118
Suggested Problems
-
816 Solvers
-
Detect a number and replace with two NaN's
187 Solvers
-
Magic is simple (for beginners)
6320 Solvers
-
find the roots of a quadratic equation
209 Solvers
-
327 Solvers
More from this Author10
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!