![](https://img-blog.csdnimg.cn/20201014180756927.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
python
pirlo-san
这个作者很懒,什么都没留下…
展开
-
Python正则表达式
1 正则表达式的使用步骤 Import the regex module with import re. Create a Regex object with the re.compile() function. (Remember to use a raw string.) Pass the string you want to search into the Regex object’s s...原创 2020-01-20 10:32:41 · 402 阅读 · 0 评论 -
Python Tips
1 builtin functions 1.1 range的三种形式 range(5) # 0 1 2 3 4 range(1, 6) # 1 2 3 4 5 range(5, 0, -1) # 5 4 3 2 1 2 作用域 There are four rules to tell whether a variable is in a local scope ...原创 2020-01-14 12:47:22 · 232 阅读 · 0 评论 -
python列表(list)、元祖(tuple)、集合(set),和字典(dictionary)的比较
数据类型 列表(list) 元祖(tuple) 集合(set) 字典(dictionary) 定义 a_list = [1, True, ‘aa’] a_tuple = (1, True, ‘aa’) a_set = {1, True, ‘aa’} a_dict = {‘name’: ‘pirlo’, ‘age’: 21} 有序 有序...原创 2018-07-01 16:47:16 · 989 阅读 · 0 评论