You are viewing a single comment's thread. Return to all comments →
this works for me
import re import sys
html= sys.stdin.read()
pattern= r'\w*.?\w+@\w+.?\w*.?\w*.?\w+'
matches=re.findall(pattern,html)
output=sorted(set(email for email in matches))
print(';'.join(output))
Seems like cookies are disabled on this browser, please enable them to open this website
Detect the Email Addresses
You are viewing a single comment's thread. Return to all comments →
Enter your code here. Read input from STDIN. Print output to STDOUT
this works for me
import re import sys
html= sys.stdin.read()
pattern= r'\w*.?\w+@\w+.?\w*.?\w*.?\w+'
matches=re.findall(pattern,html)
output=sorted(set(email for email in matches))
print(';'.join(output))