Discuss / Python / 切片器直接倒序

切片器直接倒序

Topic source

www.LC.com

#1 Created at ... [Delete] [Delete and Lock User]

def is_palindrome(n):

    s = str(n)

    s1= s[::-1]

    return s == s1


  • 1

Reply