Aufgabe 6.2 vereinfacht

main
Thore Eichhorn 2022-11-11 21:02:55 +01:00
parent 9bede4ea44
commit 8133caa0b0
1 changed files with 2 additions and 5 deletions

View File

@ -6,8 +6,5 @@ if __name__ == "__main__":
# Aufgabe 6.2 # Aufgabe 6.2
s1 = "Hello, World" s1 = "Hello, World"
tmp = "" s2 = s1[s1.find(","):0:-1]
for current_char in range(s1.find(","), -1, -1): print(s2)
tmp += s1[current_char]
s1 = tmp
print(s1)