# Matlab loop statement is driving me mad [closed]

Can someone please help me out with this loop over here? Matlab simple refuses to consider the for o=k:k-20 statement inside the if statement. :pullingmyhair:

if d(k)<=-1.5 || d(k) >=1.5
k
tab=tab+1
6

for o=k:k-20
5
if abs(d(o))<abs(d(o-1))
bench_value=o;
break;
end
end
.
.
.
.
.
end

• Wrong site. Try stackoverflow? – Louis Marascio May 25 '15 at 13:51
• I'm voting to close this question as off-topic because it would better fit on StackOverflow (but I didn't migrate because it's answered already). – Bob Jansen May 25 '15 at 15:34