is_x():
‘’‘isalpha[只包含字母且非空]’’’
‘’‘isalnum[只包含字母,数字且非空]’’’
‘’‘isdecimal[只包含数字字符且非空]’’’
‘’‘isspace[只包含\t,\n和空格]’’’
‘’‘istitle[只包含大写字母开头,后面都是小写字母]’’’
startswith() endswith()
example:
a=“hello world”
a.startswith(‘hello’)-------‘true’
a.endswith(‘world’)-------‘true’
来源:CSDN
作者:weixin_46132969
链接:https://blog.csdn.net/weixin_46132969/article/details/104072029