Python3 isalpha()方法
Python 3 教程
· 2019-02-05 21:41:34
描述
Python isalpha() 方法检测字符串是否只由字母组成。
语法
isalpha()方法语法:
str.isalpha()
参数
- 无。
返回值
如果字符串至少有一个字符并且所有字符都是字母则返回 True,否则返回 False
实例
以下实例展示了isalpha()方法的实例:
#!/usr/bin/python3 str = "codercto" print (str.isalpha()) str = "Codercto example....wow!!!" print (str.isalpha())
以上实例输出结果如下:
True False
点击查看所有 Python 3 教程 文章: https://www.codercto.com/courses/l/10.html
Web Data Mining
Bing Liu / Springer / 2011-6-26 / CAD 61.50
Web mining aims to discover useful information and knowledge from Web hyperlinks, page contents, and usage data. Although Web mining uses many conventional data mining techniques, it is not purely an ......一起来看看 《Web Data Mining》 这本书的介绍吧!