[英]Accessing a List element from another List — MATLAB
I have a question. 我有个问题。 I have an list
我有一个清单
L1 - {'a','b','c'}
L2 - {'d','e','f'}
I am storing the L1 and L2 in a separate list, so that I can loop through it ie 我将L1和L2存储在单独的列表中,以便可以循环浏览,即
X - {'L1','L2'}
Now, I am not able to do this operation X{1}{1}. 现在,我无法执行X {1} {1}的此操作。 Does any one know an alternative?
有谁知道另一种选择吗?
I need to access the element 'a' 我需要访问元素“ a”
To create the cell array of cells X
, you need to write 要创建单元格
X
的单元格数组,您需要编写
X = {L1,L2};
Then you can access X{1}{1}
然后,您可以访问
X{1}{1}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.