this is the code but this is not printing out anything
import requests
from bs4 import BeautifulSoup
htmlBody = requests.get('https://www.hindustantimes.com/tech/')
soup = BeautifulSoup(htmlBody.content, 'html.parser')
#for link in enumerate(soup.find_all(id="scroll-container")):
all_titles = soup.find_all("div", attrs={"class":"latest-news-morenews"})
for title in all_titles:
main_title = title.find("a" , attrs={"class":"media-heading"}).content
print (main_title)
this is just printing out
[Finished in 1.0s]
i want to get the headlines from this site
Thanks in advance