my $string = "smasm"; if ( $string =~ /(.).*\1$/ ) { print "$1" ; #match a double char } [download]
In reply to Re: Regex (lookahead) Confusion by valentin in thread Regex (lookahead) Confusion by ChrisR