1234567891011
#!/usr/bin/perluse warnings;use strict;my $var = "/windows/d/Perl/test/3/5/23/7";$var =~ s%(\d+)/%$1-%g;$var .= ".txt";print $var;