in reply to Need to match number other than 1

Reading it as having a sequence of 4 or 5 digits, as in '12345', and allowing sequences that do not have the '1', then simply:

my $sequence = '12345'; if( index($sequence, '1') >= 0 ) { # found the 1 digit. Interrupt here. }

--
olus