elements in our returned list is more than zero to print only lines where we found at least one substring that looks like an email address if we run the program on mbox-short txt we get the following output[';'[';'['apache@localhost)'['source@collab sakaiproject org;'['cwen@iupui edu'['source@collab sakaiproject org'['cwen@iupui edu'['cwen@iupui edu'['wagnermr@iupui edu'some of our email addresses have incorrect characters like "<or ";at the beginning or end let' declare that we are only interested in the portion of the string that starts and ends with letter or number to do thiswe use another feature of regular expressions square brackets are used to indicate set of multiple acceptable characters we are willing to consider matching in sensethe \ is asking to match the set of "non-whitespace charactersnow we will be little more explicit in terms of the characters we will match here is our new regular expression[ -za- - ]\ *@\ *[ -za-zthis is getting little complicated and you can begin to see why regular expressions are their own little language unto themselves translating this regular expressionwe are looking for substrings that start with single lowercase letteruppercase letteror number "[ -za- - ]"followed by zero or more non-blank characters (\ *)followed by an at-signfollowed by zero or more non-blank characters (\ *)followed by an uppercase or lowercase letter note that we switched from to to indicate zero or more non-blank characters since [ -za- - is already one non-blank character remember that the or applies to the single character immediately to the left of the plus or asterisk if we use this expression in our programour data is much cleanersearch for lines that have an at sign between characters the characters must be letter or number import re hand open('mbox-short txt'for line in handline line rstrip( re findall('[ -za- - ]\ *@\ *[ -za- ]'lineif len( print(xcode