requests beautifulsoup code example
Example 1: beautifulsoup and requesrs
from bs4 import BeautifulSoup
import requests
page = requests.get('https://www.timeanddate.com/worldclock/vietnam/hanoi')
soup = BeautifulSoup(page.text, 'html.parser')
soup.find_all(id='qlook')[0].find_all(id='ct')[0]
Example 2: beautifulsoup python
import bs4 as bs
import urllib.request
source = urllib.request.urlopen('https://pythonprogramming.net/parsememcparseface/').read()