generating a sequence 1,2,3,4,....,n
118 次查看(过去 30 天)
显示 更早的评论
Without using a for loop, how can I generate an index 1,2,3,...,n?
0 个评论
采纳的回答
R.U.F.
2012-4-21
vector=[1:stepsize:n] if the stepsize =1 as in your case, you can disregard it
1 个评论
更多回答(1 个)
另请参阅
类别
在 Help Center 和 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!