Advertisement
here2share

# regex_backslash_one.py

Apr 26th, 2019
232
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.19 KB | None | 0 0
  1. # regex_backslash_one.py
  2.  
  3. import re
  4.  
  5. def regex(test):
  6.     print test, '=', bool(re.findall(r'(\d)\1{3}',test))
  7. #
  8. regex('120003')
  9. regex('1200003')
  10. regex('12000003')
  11.  
  12. # target = '0000'+
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement