from urllib.request import urlopenfrom bs4 import BeautifulSouphtml=urlopen("http://www.pythonscraping.com/pages/page1.html")bsobj=BeautifulSoup(html.read())print(bsobj.h1)