Initial Commit

This commit is contained in:
Hofei90
2020-04-03 09:39:48 +02:00
parent 71aea7c242
commit 362ef48409
8 changed files with 479 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
import requests
from bs4 import BeautifulSoup
countrys = ["Germany"]
URL = "https://countrymeters.info/en/"
def scrape_bev(land):
r = requests.get(f"{URL}{land}")
soup = BeautifulSoup(r.text, features="html5lib")
table = soup.find("div", {"id": "cp1"})
print(table)
scrape_bev("Germany")