$ perl -ne 'print if $. == 1234687' input.txt #### $ perl -ne 'print and exit if $. == 1234687' input.txt