line numbers inside the frame box latex listing# code example Example: lstinputlisting line range \lstinputlisting[firstline=300,lastline=500]{file.cc}