while (<>) { next if ( /^\s*;/ or /;;/ ); # now do stuff... }