in reply to Re^3: Return string that starts and ends with specific characters
in thread Return string that starts and ends with specific characters

to clarify, I want it to start at any available "f", but end at only the first "j" after that "f". Thanks
  • Comment on Re^4: Return string that starts and ends with specific characters

Replies are listed 'Best First'.
Re^5: Return string that starts and ends with specific characters
by Anonymous Monk on Jun 02, 2016 at 17:34 UTC
    #!/usr/bin/perl # http://perlmonks.org/?node_id=1164776 use strict; use warnings; print "$1\n" while 'asdfgfhjkljjj' =~ /(?=(f.*?j))/g