Struggled with this code so I opted for the ‘Get Code’ after a few unsuccessful attempts. I’m looking for some clarity on what some of the lines in the function does. Thanks!
def reverse(text): word = "" l = len(text) - 1 #this variable takes the length of 'text' and subtracts 1? Is this the same argument in the function? while l >= 0: word = word + text[l] # do not understand this, please help l -= 1 return word print reverse("text")