Ah, thank you very much, defined sounds like exactly the type of thing I was looking for. I think I even skimmed over the perldoc for it before (I did learn about the existence of defined from a quick mention of it in "Learning Perl") but erroneously disregarded it in this case due to the perldoc bit that says "Use of defined on aggregates (hashes and arrays) is deprecated." Which is my fault for skimming rather than actually RTFM'ing, because the perldoc is pretty clear about what it actually meant by "use... on aggregates" via the examples it gives, and it doesn't mention anything being frowned upon for using defined in a scalar context on a single array element like the defined($columns[1]) you show.
Small follow up question. You chose to add parenthesis and switch the and to an && instead. I understand the different order of precedence between and vs. &&, but is there a reason you elected to rewrite it that way? Or is just a case of, "that's just the way I decided to write it"?
EDIT: Sorry, my brain saw added parenthesis where there were none.
In reply to Re^5: Removing partially duplicated lines from a file
by perldigious
in thread Removing partially duplicated lines from a file
by Sandy_Bio_Perl
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |