From 070d773d5146755f347b7c131947ac1c27a95c40 Mon Sep 17 00:00:00 2001 From: Phil <2121464@stud.hs-mannheim.de> Date: Tue, 10 Jan 2023 12:09:58 +0100 Subject: [PATCH] moritz lutz schau dir was bei mir ab --- gottkönigphil.py | 11 +++++++++++ input.txt | 4 ++++ personen.json | 1 + 3 files changed, 16 insertions(+) create mode 100644 gottkönigphil.py create mode 100644 input.txt create mode 100644 personen.json diff --git a/gottkönigphil.py b/gottkönigphil.py new file mode 100644 index 0000000..54a299e --- /dev/null +++ b/gottkönigphil.py @@ -0,0 +1,11 @@ +import json + + + +with open('z.B._pr3_skriptspr_team12_s2\input.txt', 'r') as infile, open('z.B._pr3_skriptspr_team12_s2\personen.json', 'w') as outfile: + for line in infile: + + + + + json.dump(line, outfile, indent = 2, ensure_ascii=False) diff --git a/input.txt b/input.txt new file mode 100644 index 0000000..04419bd --- /dev/null +++ b/input.txt @@ -0,0 +1,4 @@ +Dr. Philipp Gottkönig, Schloss 1 68161 Mannheim, 10.11.1995 + +Knecht Moritz Luttz, Kerker 4 198237918 Offenbach, 6 Winter ago + diff --git a/personen.json b/personen.json new file mode 100644 index 0000000..1a3c7c6 --- /dev/null +++ b/personen.json @@ -0,0 +1 @@ +"Dr. Philipp Gottkönig, Schloss 1 68161 Mannheim, 10.11.1995\n""\n""Knecht Moritz Luttz, Kerker 4 198237918 Offenbach, 6 Winter ago\n""\n" \ No newline at end of file