fork download
  1. import re
  2. s="$$%%%%"
  3. pat=r'\w+'
  4. if re.search(pat,s):
  5. mi_no_find = re.finditer(pat,s) # not matching.
  6. count = 0
  7. if len(mi_no_find) > 0:
  8. for m in mi_no_find:
  9. print(m.group())
  10. count += 1
  11. print(count)
  12. else:
  13. print("-1")
  14.  
Success #stdin #stdout 0.02s 27712KB
stdin
Standard input is empty
stdout
-1