Using Octave: Difference between revisions

7 bytes removed ,  21 April 2017
(→‎Control flow with loops: Correct spelling)
Line 126: Line 126:
k = 1;
k = 1;
step = 2;
step = 2;
while (k <= (100-step))
while (k <= 100)
   y(i) = k^2;
   y(k) = k^2;
   k = k + step;
   k = k + step;
endwhile</syntaxhighlight>
endwhile</syntaxhighlight>
Anonymous user