in reply to (How) can I use regex patterns to find matching lines in a textfile?
system ("grep pattern | head -maxnumberofmacthes"); [download]