Question: Below I have attached the question. The second image shows how the data is structured. Can anyone help me out plz Task #1: Collect all

Task #1: Collect all of the file paths of emails in the maildir (1 points) The output object will be called list_emails should contain 79.429 items and look similar to the following: I'maildirilallen-p\\inbox\\10_'. mildir tallen-p\\inbox\\11_ maildir tallen-p\\inbox\\12_, naildirilallen-pl inbox\\13_. maildirilallen-p\\inbox\\14_ 'naildirilallen-p\\inbox\\15 mildirilallen-p\\inbox\\16_'. naildirilallen-p\\inbox\\17_", maildirilallen-pilinbox\\18_ maildirallen-p\\inbox\\19_ 1 The broad strokes to creating this ist goes as follows: use the command os. listdirl'maildir) to see the folders in the mal directory . then use the command os. listdir(maildir/allen-p') to see the folder in Alen Ps folder . then use the command os. Listdirnaildir/allen-p/inbox) to see the contents in Allen P's inbox and collect the full file paths you need to who collect the fles in both the inbox and sent items folders for Allen P, do not trackerals from the other folders next move on to Arnold JI next move onto Ayora Light bulbs should start going off in your head at this point about ways to solve this problem. This is a repeated process that needs to happen any many times. A for loop is the simplest way to solve a repetitive task Use for loops to collect al 79,429 le paths into a single lat. Hints look up os.path.joint-strings if you are having trouble creating the appropriate argument for the os. listdir) command in the following cat produce the let of emais directed and save the rest to the object listened Loaths In 1811 Laperto Task 0: Download dataset and explore It The research dataset is located here, maintained by Carnegie Melton University, https://www.cs.cmu.edu/-enton. Though due to its size we have created a smaller version on Google Drive Download the pared down enron data file here. Place the maidir directory from the zip file into the main folder of your gt repository The bullets below represent the file structure of interest from the Enron dataset. To confirm that you have unzipped and placed the data in the correct location, click on the links of Res. e. 1. 2.. etc., which will open the text files for you to explore, Notice that these are all raw text filen. maldir . We Inbox * 1 2 entiem . - 2 3. etc. A. arnold - Inbox . otoms -1 2 3 borah
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
