python how to read a txt file for a specific word code example
Example 1: how to read specific words from a file in python
fo = open("output.txt", "r+")
str = fo.readline()
str = str[7:11]
print("Read String is : ", str)
fo.close()
Example 2: how to read specific words from a file in python
fo = open("output.txt", "r+")
str = fo.readline()
str = str[7:11]
print "Read String is : ", str
fo.close()