Aufgabe 6.2 vereinfacht
parent
9bede4ea44
commit
8133caa0b0
|
@ -6,8 +6,5 @@ if __name__ == "__main__":
|
|||
|
||||
# Aufgabe 6.2
|
||||
s1 = "Hello, World"
|
||||
tmp = ""
|
||||
for current_char in range(s1.find(","), -1, -1):
|
||||
tmp += s1[current_char]
|
||||
s1 = tmp
|
||||
print(s1)
|
||||
s2 = s1[s1.find(","):0:-1]
|
||||
print(s2)
|
||||
|
|
Loading…
Reference in New Issue