Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
column
· 13y ago · 0 comments
I would answer :
def reverse(str): return str[::-1]
Am I missing the point ?
Comments
[–]
prezjordan
13y ago
That creates a new string (the one returned) :)
[–]
freework
13y ago
Thats what I would do. Then again, I always get rejected when I do these type of interviews...