while (<> and !/pattern/) {} #### while (defined($_ = <>) and !/pattern) {}