perl -e 'map{($a=$_)=~s/REPT/ERR/,rename($_,$a)}glob("*.REPT")'
####
perl -e '$var = "\@m=glob(\"*\");\@m = grep{m/\d+_\d+\.REPT/g} \@m; foreach(\@m){$s=$_;$s=~s/REPT/ERR/; rename($_,$s);}";print length($var),"\n";'
83
####
perl -e '$var = "map{($a=$_)=~s/REPT/ERR/,rename($_,$a)}glob(\"*.REPT\")";print length($var),"\n";'
45
####
[qadmin@concon qw]$ ls -1 *REPT *ERR
ls: *ERR: No such file or directory
353513_3.REPT
42342_12.REPT
442342_2.REPT
[qadmin@concon qw]$ perl -e 'map{($a=$_)=~s/REPT/ERR/,rename($_,$a)}glob("*.REPT")'
[qadmin@concon qw]$ ls -1 *REPT *ERR
ls: *REPT: No such file or directory
353513_3.ERR
42342_12.ERR
442342_2.ERR
[qadmin@concon qw]$