use strict; use warnings; my $ref; my ($A,$B); while (<DATA>) { chomp; if (s/^\s+//) { eval "\$$ref = $_" } else {$ref = $_} } print "A=$A and B=$B\n"; __DATA__ A 33 B 22
In reply to Re^3: regex issue
by Roy Johnson
in thread regex issue
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |