Problem 61055. Enclosure Matrix
The problem gives you a positive integer n. You need to create a matrix consisting of n layers of natural numbers; the outermost layer contains the number n, the second layer contains n − 1, and so on, until the innermost layer contains the number 1.
For example:
n=3
y=[ 3 3 3 3 3
3 2 2 2 3
3 2 1 2 3
3 2 2 2 3
3 3 3 3 3 ];
Solution Stats
Solution Comments
Show commentsProblem Recent Solvers7
Suggested Problems
-
7 Solvers
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!