Files
devops/perl/Examples/Chap8/regex-g-demo
2025-09-17 16:08:16 +08:00

13 lines
179 B
Plaintext

###
### regex-g-demo
###
## Chapter 8 section 1.2
my $target = "123..45.6789...0";
while ($target =~ /(\d+)/g) {
print "Saw '$1' ending at position ", pos($target), "\n";
}