-
1 Comment
Erik Zdanskyon 3 Feb 2016
The intention was to make a correct preallocation and the fill it without needing to extend the string or reshuffle its content. It would be good to gain more insight into how the size is calculated. Criteria for evaluating code is not only code size but memory and time efficiency, and efficiency in writing and maintaining the code.
Suggested Problems
Sum of diagonal of a square matrix
1443 Solvers
Create matrix of replicated elements
343 Solvers
272 Solvers
Find the index of the largest value in any vector X=[4,3,4,5,9,12,0,4.....5]
334 Solvers
Matlab Basics - Absolute Value
468 Solvers
More from this Author95
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!