vendredi 22 mai 2015

Perl shorthand for if statement

I have the following code in Perl:

next if ++$count == 1;

which should be the equivalent of

if (++$count == 1) {
    next;
}

Is there a way to run next; if I add more conditions? (i.e. if ++$count is equal to 1 or greater than some other value?

Aucun commentaire:

Enregistrer un commentaire