I need my loop to skip iterations to a given index. When i try it the obvious way like below
for i=2:1:(dim(1)-2)%(a lot of irrelevant if statements)
%skip through points in the same hole
while graph(j) < tor j=j+1; end if j < dim(1) - 2 i=j; % <== here is the problem
endend
im getting a warning "LOOP index is changed inside of a FOR loop." and program ignores my iterator override.
How can i do this properly? or work around this?
Best Answer