import httpx
from bs4 import BeautifulSoup
defget_text():
url ='https://movie.douban.com/chart'
res = httpx.get(url,headers={'user-agent':'dsncns'})
html = BeautifulSoup(res.text,'lxml')
title = html.select('.item > td > div')for i in title:print(i.get_text())
get_text()