Your skill will accomplish what the force of many cannot |
|
PerlMonks |
Puzzling Hash of Arrays problemby Tuna (Friar) |
on Apr 21, 2001 at 01:58 UTC ( [id://74345]=perlquestion: print w/replies, xml ) | Need Help?? |
Tuna has asked for the wisdom of the Perl Monks concerning the following question:
I have a program which, among other things, reads archived files containg the output of "show diagbus" on Cisco routers. The relevant strings I'm matching in my regex are:
L3 Engine: 0 - OC12 (622 Mbps) L3 Engine: 1 - OC12 (622 Mbps) L3 Engine: 2 - OC12 (622 Mbps) L3 Engine: 4 - OC12 (622 Mbps) Here's a code snippet: this successfully prints: router1 - Engine 0,2, router2 - Engine 1,2 router3 - Engine 2 router4 - Engine NA ...etc. Except, it won't print instances of: router1 - Engine 0 Something about pushing one "0" and nothing else into my HoL fails. Can anyone help a poor Monk out?
Back to
Seekers of Perl Wisdom
|
|