#!/usr/bin/perl -w use strict; my $i = 4; for ( 1 .. 9, -12 ) { print if /$i/; }