> A quick suggestion: > > if -1 not in [line.find(x) for x in ["KeC 923","ZEF 156","pBX > 88347","FZX 17255"]]: > # etc. Still searches three times but at least its more maintainable. A regex in this case will almost certainly be faster than repeated searching. Alan G.