in reply to Regex backreference problem.

I'd think of this: ($f)=~/(.)/; /(.)([^$f])/ and print $1,$2;