Undefined variable "U"
显示 更早的评论
E = [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0];
E1 = [0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0];
e = 1;
E(1) = U{1}(1);
e = e + 1;
e1 = 1;
E1(1) = U{1}(2);
e1 = e1 + 1;
for i = 1:numel(U)
a = U{i};
for t = 1:numel(E)
if a(1) == E(t);
E1(e1) = a(2);
e1 = e1 + 1;
else if a(2) == E(t);
E1(e1) = a(1);
e1 = e1 + 1;
end
end
end
help pls how can i define it
1 个评论
Stephen23
2017-12-14
@Evaldas Kuslevic: today I formatted you code correctly for you. In future you can do it yourself: first select the code, then click the {} Code button.
采纳的回答
更多回答(1 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Logical 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!