站长资源脚本专栏
使用 use re debug 查看正则表达式的匹配过程
简介复制代码 代码如下:#!/usr/bin/perluse strict;use warnings;use re 'debug';sub test { my $str = "123456789"; print join(":", split /(?<=...)/, $str);}test(
复制代码 代码如下:
#!/usr/bin/perl
use strict;
use warnings;
use re 'debug';
sub test {
my $str = "123456789";
print join(":", split /(?<=...)/, $str);
}
test();
#!/usr/bin/perl
use strict;
use warnings;
use re 'debug';
sub test {
my $str = "123456789";
print join(":", split /(?<=...)/, $str);
}
test();