-
카테고리
-
세부 분야
데이터 분석
-
해결 여부
미해결
과제 질문
21.07.06 21:38 작성 조회수 115
0
from bs4 import BeautifulSoup
import urllib.request as req
import urllib.parse as rep
import sys
import io
sys.stdout = io.TextIOWrapper(sys.stdout.detach(), encoding = 'utf-8')
sys.stderr = io.TextIOWrapper(sys.stderr.detach(), encoding = 'utf-8')
url = "https://www.daum.net/"
res = req.urlopen(url).read()
soup = BeautifulSoup(res, "html.parser")
top = soup.select("ul.list_inner")[0]
print(top)
#for i,e in enumerate(top,1):
#print(i,e.select_one("h4.block_title > a").string)
분명히 웹사이트에는 내용이 있는데 출력해보면 빈리스트만 나오네요 왜이러는거죠?
답변을 작성해보세요.
1
답변 1