- or download this
# provided by the outermost if
$1 = undef;
...
$2 = 'bb';
$3 = 'cc';
}
- or download this
$_ = "aabbccdd";
if ( /^(\w\w)\w\w(\w\w)\w\w$/ ) {
...
print "mid: $1 $2\n"; # the inner if's vars are still accessible h
+ere
}
print "outer: $1 $2\n";
- or download this
$_ = "aabbccdd";
/^(\w\w)\w\w(\w\w)\w\w$/;
...
print "mid: $1 $2\n";
}
print "outer: $1 $2\n";