help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

A "cycle" command for octave ?


From: Madhusudan Singh
Subject: A "cycle" command for octave ?
Date: Tue, 13 Sep 2005 11:10:13 -0400
User-agent: KMail/1.7.2

Hi

I know that Matlab does not seem to offer this functionality, but I was 
wondering if a future version of octave could include the equivalent of a 
Fortran 95 cycle command ?

Basically what it does is go to the next iteration in a for or a while loop :

Fortran 95 :

do i = 1,10
if (f(a,i).eq.0.0) cycle
...
...
...
enddo

where f is a function and a is any argument.

I know it is possible to replicate this functionality by using an if-else 
block, but that sphaggetizes the code if the loop is very long and 
complicated.

Thanks



-------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.octave.org
How to fund new projects:  http://www.octave.org/funding.html
Subscription information:  http://www.octave.org/archive.html
-------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]