Develop a crawler that collects the email addresses in the visited web pages. You can write a function emails() that takes a document (as a string) as input and returns the distinct email addresses appearing in it [remove duplicate email addresses]. You should use a regular expression to find the email addresses in the document. Use your WebCrawler to check email links in html Absolute HTTP link Absolute link to Google Relative HTTP link Relative link to test.html. mailto scheme Click here to email somebody. Click here to email somebody. Click here to email nobody. Click here to email nobody. Click here to email anybody. Click here to email anybody. Click here to email everybody.
Develop a crawler that collects the email addresses in the visited web pages. You can write a function emails() that takes a document (as a string) as input and returns the distinct email addresses appearing in it [remove duplicate email addresses]. You should use a regular expression to find the email addresses in the document.
- Use your WebCrawler to check email links in html
<html>
<body>
<h4>Absolute HTTP link</h4>
<a href="http://www.google.com">Absolute link to Google</a>
<h4>Relative HTTP link</h4>
<a href="test.html">Relative link to test.html.</a>
<h4>mailto scheme</h4>
<a href="mailto:somebody@example.net">Click here to email somebody. </a><br>
<a href="mailto:somebody@example.net">Click here to email somebody.</a><br>
<a href="mailto:nobody@example.net">Click here to email nobody.</a><br>
<a href="mailto:nobody@example.net">Click here to email nobody.</a><br>
<a href="mailto:anybody@example.net">Click here to email anybody.</a><br>
<a href="mailto:anybody@example.net">Click here to email anybody.</a><br>
<a href="mailto:everybody@example.net">Click here to email everybody.</a><br></body>
</html>
Trending now
This is a popular solution!
Step by step
Solved in 2 steps