Problem 943. "mirror" matrix
Create n x 2n "mirror" matrix of this type:
Examples
For n = 2
m = [ 1 2 2 1 1 2 2 1 ]
For n = 3
m = [ 1 2 3 3 2 1 1 2 3 3 2 1 1 2 3 3 2 1 ]
Solution Stats
Problem Comments
-
1 Comment
Aditya Deshpande
on 17 Jul 2017
This problem was fun. I was able to find a better way to solve beat my own solution. Not the best way though. But lot better.
Solution Comments
Show commentsProblem Recent Solvers641
Suggested Problems
-
The Hitchhiker's Guide to MATLAB
3327 Solvers
-
Back to basics 25 - Valid variable names
328 Solvers
-
Create a square matrix of multiples
482 Solvers
-
1411 Solvers
-
1807 Solvers
More from this Author9
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!