display specific lines in a file Posted byepsilon May 29, 2013January 26, 2021 sed -n “20,40p” filename will display lines from 20 to 40 in the file.