软件编程版 #102372 层

数组里的数据 能不能作为另一数组的索引?

楼主 · 1 楼
数组里的数据可以作为另一数组的索引。
你上面的程序可以运行啊。
2 楼
比方说 a = [ 1 2 3 4 ];
b = [34 43 56 1];

b( a(2) ) = ?

有时候正确 有时候 就会产生错误: Subscript indices must either be real positive integers or logicals.

怎么解决阿??