fork download
  1. # your code goes here
  2. import re
  3. resume = '''
  4. (738) 383-5729
  5. (373) 577-0492
  6. (403) 443-2759
  7. (375) 880-8576
  8. hello regex
  9. (641) 576-2342
  10. some text
  11. (951) 268-8744
  12. '''
  13.  
  14.  
  15. mo = re.findall(r'\(\d+\) \d{3}-\d{4}', resume)
  16.  
  17. for x in mo:
  18. print(x)
Success #stdin #stdout 0.02s 27712KB
stdin
Standard input is empty
stdout
(738) 383-5729
(373) 577-0492
(403) 443-2759
(375) 880-8576
(641) 576-2342
(951) 268-8744