#!perl -pl s/@{[s".."."gr]}\K$"// #Please, could you post some explanations? #Seems black magic too me #s/@{[s".."."gr]}/$& / <= wrong