chomp; while (length($_) > 80) { print substr( $_, 0, 80) . "\n"; $_ = substr( $_, 80, length($_) - 80); } print;