Problem 43995. convert 2D array of ones and zeros to checkerboard array of [1,2] where the original array was ones and zero elsewhere
Solution Stats
Problem Comments
-
1 Comment
yurenchu
on 10 Jan 2017
You should add a test case where the last row and/or last column of x contains only zeroes.
Problem Recent Solvers21
Suggested Problems
-
1129 Solvers
-
Reverse the elements of an array
778 Solvers
-
185 Solvers
-
Test Problem; Create a 5x5 array containing all ones
328 Solvers
-
79 Solvers
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!