I want to use all the values present in two arrays but if I run for loops (ie) I used two for loops but only the last value of both the arrays are taken. What is the syntax so that I can use all my values of both arrays simultaneously.?
2 次查看(过去 30 天)
显示 更早的评论
I want to use all the values present in two or three arrays but if I run for loops (ie) I used three "for" loops but only the last value of both the arrays are taken. What is the syntax so that I can use all my values of both arrays simultaneously.?
for p1= [60 78 132 12 26 10 150 156 172 168 159 174]
for p2=[61 150 16 24 25 8 155 164 173 160 171 169]
for s=[0 1 2 3 4 5 6 7 8 9 10 11]
these are the three loops...at first iteration I need 60,61,11 next iteration 78,150,1 and so on.
0 个评论
采纳的回答
更多回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Logical 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!