在python中反转字符串,而不使用reversed()或[::-1]
def reverse(test): n = len(test) x="" for i in range(n-1,-1,-1): x += test[i] return x