import requests
from bs4 import BeautifulSoup
res = requests.get("http://www.nfd.com.tw/house/year/2016.htm")
soup= BeautifulSoup(res.text)
tb = soup.select('table')[0]
tr = tb.select('tr')
print tr[0]
for i in tr:
print i.select('td')
沒有留言:
張貼留言