sorry m8s i wrote a klausur today

This commit is contained in:
TheShinyMelon 2022-12-09 22:59:42 +01:00
parent 3284a8e002
commit 35d05b5d18

View File

@ -1,13 +1,19 @@
inputFile = open("./input.txt", 'a+')
for c in inputFile:
area = inputFile.read(4)
check = ""
for a in area:
if a not in check:
check += a
if(check==area):
break
with open("./input.txt", 'r') as input_file:
i = 0
tmp_str = ""
print("Stelle des heiligen Pandabären: ", inputFile.tell())
print("Der Text an der Stelle: ", inputFile.seek(inputFile.tell()-1)) #hilf
for c in input_file.read():
tmp_str += c
i += 1
if len(tmp_str) > 3:
area = tmp_str
tmp_str = ""
check = ""
for a in area:
if a not in check:
check += a
if check==area:
break
print(tmp_str)