use strict; while (<DATA>) { chomp; $_ = $` if /#/; print "$_\n" if $_; } __DATA__ ### Hello 99:88:77 100:11# This is a comment abc:def ### Comments also 999
--Jim
Update: shortenned conditional after chomp;
In reply to Re: Support for hash comments on a line
by jlongino
in thread Support for hash comments on a line
by c
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |