I don't know how to do something like this in python:
I have a string s = 'windows 95 is not a windows nt operating system'
, and I want to get string that contains 'nt' and a number of nearby letters, including spaces.
Expected output for 7 nearby letters:
'indows nt operat'
If it is impossible, then is it possible to get the index of a string I want to find like this:
>>> s = 'windows xp horray'
>>> stringtofind = 'hor'
Expected output:
11, 12, 13
Where I only want to get 11
because it is the start."
Is this possible?