in reply to Regular expression matching or eq, which is faster?
- If you are looking for equality between two strings, use eq
- If you need to match against a regular expression, use a regular expression
- If your regular expression needs to match from the beginning of the string, use the ^ anchor. If your regular expression matches until the end of the string, use the $ anchor
citromatik
In Section
Seekers of Perl Wisdom