Notes: Very Basic Concepts On Loops
If you are struggling with working with loops, in addition to examples
in the lecture notes and in the book, try these 1) as written, and
2) changed in ways until you understand exactly how they work.
for n=1:10
n
end
A=[1 .5 .2 7.8 9]
for k=A
k
end
Last update: April 30, 2011