Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python get line number x in file

f=open('filename')
lines=f.readlines()
print lines[25]
print lines[29]
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #python #line #number #file
ADD COMMENT
Topic
Name
3+1 =