Fred Nastos wrote:
>
> On December 14, 2003 01:21 pm, km wrote:
> >
> > but if i need to set a hop for each number how do i get it ? something like
> > stride functionality so that it will print 1,4,7,10 something like
> >
> > for(1..10 ,jump 3)
> > {
> > print;
> > }
>
> How about the old-fashioned way?
>
> for ($i=1; $i<=10) {
> print $i, "\n";
> $i = $i + 3;
> }
That produces a syntax error, it won't run.
John
--
use Perl;
program
fulfillment
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>