#Used to make requests import urllib.request x = urllib.request.urlopen('https://www.google.com/') print(x.read())
Here is what the above code is Doing:
1. urllib.request is imported
2. urllib.request.urlopen(‘https://www.google.com/’) is called, which returns an object of class http.client.HTTPResponse
3. The read() method is called on this object, which returns the HTML of the page as a string