最佳答案
一个例子:
>> x = randi(10, [1 5])
x =
9 7 4 10 1
>> x.^(1:numel(x))
ans =
9 49 64 10000 1
关于matlab - 考虑到 matlab 中的索引,如何最好地遍历数组?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/2307135/