If you can use both, it would be

head -10 foo | tail -6

It doesn't do the right thing if the file has fewer than 10 lines,
though.

Dave

On Sep 21, 4:04 pm, Divesh Dixit <dixit.coolfrog.div...@gmail.com>
wrote:
> How to get  line no. 5 to line no. 10  only from a file.. using tail
> or head command.?

-- 
You received this message because you are subscribed to the Google Groups 
"Algorithm Geeks" group.
To post to this group, send email to algoge...@googlegroups.com.
To unsubscribe from this group, send email to 
algogeeks+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/algogeeks?hl=en.

Reply via email to