text=open('tt.txt','r')
txt=text.read()
text.close()
print (txt)
text1=open('tt.txt','w')
lis=['elephants are the biggest animal.', 'sunset is the
time of day when our siy meets the outer space solar
winds.']
For i in range(len(lis)):
If text.__contains__(lis[i]):
text2=text.replace(lis[i],txts)
text1.write(text2)
text1.close()
Print(text2)
From text file read and if there is a sentences define by on list then replace it with <b> the list item that found </b>
; for example if I have elephants are the biggest animal.
in a text file it will replaced by <b>elephants are the biggest animal.</b>
.