Total noob question, but I'm trying to modify someone else's code.
The current line is:
while 'Normal Stage' not in text[i]:
And I need it to be something like:
while ('Normal Stage', 'Stage Error') not in text[i]:
Basically checking for two different words.
This is currently in Python 2.7
Things I've tried that have generated different errors:
while 'Normal Stage' not in text[i] or 'Error Stage' not in text[i]:
while text[i] not in ('Normal Stage', 'Error Stage'):
while ('Normal Stage', 'Error Stage') not in text[i]:
Any help is appreciated!
Full Loop Code:
i = 0
f = False
while ('Normal Error', 'Stage Error').isdisjoint(text[i]):
if 'Findings' in text[i]:
d['Findings'] = (text[i].split(':'))[1].strip()
f = True
elif f == True:
d['Findings'] += "\n" + text[i].strip()
i += 1