📅  最后修改于: 2022-03-11 14:46:20.630000             🧑  作者: Mango
from contextlib import closing
import csv
# STEP 1:
# Baca file "harga_rumah.txt"
url = "url"
data = []
with closing(requests.get(url, stream=True)) as r:
f = (line.decode('utf-8') for line in r.iter_lines())
data = [row for row in csv.reader(f)]