If 'ifSpeed' is seen then the index is found but $2 is set if the second format is seen.if (/^ifSpeed.(\d+)|^1.3.6.1.2.1.2.2.1.5.(\d+)/){ print "Index: $1\n"; }
In reply to regex question/mystery by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |