Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
abracadabra
def find_end(string): start = 0 end = len(string) - 1 r = [] str1 = '' str2 = '' while start < end: str1 = str1 + string[start] str2 = string[end] + str2 if str1 == str2: r.append(str1) start += 1 end -= 1 return r[-1] if len(r) > 0 else 'no' print(find_end('abracadabra')) print(find_end('stringstring'))
run
|
edit
|
history
|
help
0
ganesh
Lesson 2-ex
mansur
Name
sensi cod
PyRegGreed
sheru
IP Network and Broadcast calculator
Faiha - L6
f strings 2