generate matrix by for loop
이전 댓글 표시
A=[1 -10 4
0 -2 7
5 1 9]
I need to get
A=[1 0 -10 0 4
0 0 -2 0 7
5 0 1 0 9]
by for loop
댓글 수: 1
David Meissner
2022년 6월 6일
I would look into "Indexing with a Single Index" here: https://www.mathworks.com/help/matlab/math/array-indexing.html
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!