fork download
  1. import re
  2. words = ['session', 'curl']
  3. month = 'Dec'
  4. x = '|'.join([re.escape(w) for w in words])
  5. m = re.search(r'^(?!.*({})).*{}'.format(x, month), 'Date: Dec 2016')
  6. if m:
  7. print('Matched')
Success #stdin #stdout 0s 9024KB
stdin
Standard input is empty
stdout
Matched