How to display from line 10 to line 23 in from passwd using tail?
I know that using tail -1/etc/passwd
It will display last line from passwd
So please help.
How to display from line 10 to line 23 in from passwd using tail?
I know that using tail -1/etc/passwd
It will display last line from passwd
So please help.
You can combine the commands "head" and "tail" like so:
head -n23 filename | tail -n14
Like Squall5668 posted, you would have to use head and tail programs together. As an alternative, you may prefer to use sed as a single command, like this
sed -n '10,23p' filename