import requestsfrom bs4 import BeautifulSoupurl = 'https://www.universitego.com/bilgisayar-muhendisligi-2021-taban-puanlari-ve-basari-siralamalari/'soup = BeautifulSoup(requests.get(url).content.decode('utf-8', 'ignore'), 'html.parser')for span in soup.select('tr > td:nth-child(1)'): print(span.get_text(strip=True, separator=' ')) print('-' * 80)我使用上面的代码从以下网站获取有关该部门的部门和表格。然而,我运行后得到了一个空列表。我应该怎么办?谢谢。网站 https://www.universitego.com/4-yillik-bolumlerin-2015-2016-taban-puanlari-ve-basari-siralamalari/ https://www.universitego.com/bilgisayar-muhendisligi-2021-taban-puanlari -ve-basari-siralamalari/
添加回答
举报
0/150
提交
取消