Say I have the following:
vector = [1,2,3];
if length(vector) > 5
error ('Vector too long')
elseif
for k = 1:length(vector)
vector(1,k) < vector(1,k+1)
error ('Elements in vector not in ascending order')
else
...
I cannot seem to get this to work, nor can I see an obvious way to get around this problem.
Aucun commentaire:
Enregistrer un commentaire