in reply to Creating regex from arrays
It also rather niftily 'optimizes' (or 'compresses', depending on your view) the regular expression for overlapping words. See. the Regex::PreSuf docs for more info.use Regex::PreSuf; print presuf("1234", "ABCD", "HIGL", "TOOA", "COOLIE"); __output__ (?:1234|ABCD|COOLIE|HIGL|TOOA)
_________
broquaint
|
|---|