s ="Python" # initial string. 2. stringlength=len(s) # calculate length of the list. 3. slicedString=s[stringlength::-1] # slicing.
確定! 回上一頁