Berufsschule/S1/LF5/2022-03-14_Adressen.py

14 lines
240 B
Python
Raw Normal View History

2022-03-17 09:47:01 +01:00
from pathlib import Path
adressen = Path("adressen.txt").read_text()
telefon = {}
for l in adressen.split("\n"):
if l == "":
continue
zeile = l.replace(";",",").split(",")
telefon[zeile[0]] = zeile[3]
print(telefon)