Tip #1 from the Basic debugging checklist: use warnings. Tip #2 print.
In reply to Re: Arrays and grep problems by toolic in thread lolhackedlol by perlmonknoob