matlab运行后输入几个值总是警告,Unexpected MATLAB expression
done=0;k=1;v=input('arowvector:');while~done,done=1;forp=1:(length(v)-k),ifv(p)>v(p+1...
done=0;
k=1;
v=input('a row vector:');
while ~done,
done=1;
for p=1:(length(v)-k),
if v(p)>v(p+1),
tmp=v(p);v(p)=v(p+1);v(p+1)=tmp;
done=0;
end
end
k=k+1;
end 展开
k=1;
v=input('a row vector:');
while ~done,
done=1;
for p=1:(length(v)-k),
if v(p)>v(p+1),
tmp=v(p);v(p)=v(p+1);v(p+1)=tmp;
done=0;
end
end
k=k+1;
end 展开
1个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询