Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

I need to write code on python (can use only json and csv librarys) I have 4 html files (first.html , second.html , third.html, fourth.html)

I need to write code on python (can use only json and csv librarys) I have 4 html files (first.html , second.html , third.html, fourth.html) with hyperlinks inside. Inside first.html I have link second.html, that opens second.html file and link third.html , that open third.html. second.html dont have links inside. third.html have links first.html that open first.html and fourth.html that open fourth.html . fourth.html have link first.html that open first.html. need to write smth like crawler that checks all files and links inside and put it in dictionary. dictionary, where keys is names of file and values are name of links inside. for example, the dictionary might be like: {'first.html': ['second.html', 'third.html'], 'second.html': [], 'third.html': ['first.html', 'fourth.html'], 'fourth.html': ['first.html']}

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Databases DeMYSTiFieD

Authors: Andy Oppel

2nd Edition

0071747990, 978-0071747998

More Books

Students also viewed these Databases questions