Info
此问题已关闭。 请重新打开它进行编辑或回答。
how to change this code for search from last column to search from first column?
1 次查看(过去 30 天)
显示 更早的评论
[n1,m1]=size(Complete_Fill);
for k=1:n1
id_before=strfind(Complete_Fill(k,:),[0 1]);
id_after=strfind(Complete_Fill(k,:),[1 0])+1;
Complete_Fill(k,[id_before id_after])= -1;
end
X = randi([0 1], n1,m1);
index = (Complete_Fill(:) ~= 0);
X(index) = Complete_Fill(index)
0 个评论
回答(1 个)
此问题已关闭。
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!