跳过正文

Python

Python Redis
·147 字
连接redis # import redis # 连接redis def connect_redis(host, port, password): # decode_responses: 是否deco
Requests库
·128 字
简单Get请求 # #!/usr/bin/python3 import requests # get返回html文本 def getData(url): result = requests.get(url) print(result.json()) if
Python100天-多进程多线程编程
·357 字
多进程示例 # from multiprocessing import Process from os import getpid from random import randint from time import time, sleep def download_task(filename): print
Python100天 文件操作
·959 字
文件操作模式 # 操作模式 具体含义 r 只读(默认) w 写入,会清空之
Python100天-面向对象编程
·1293 字
面向对象 # 把一组数据结构和处理它们的方法组成对象(objec
Python100天-数据类型
·2137 字
字符串 # 获取字符串长度 # s = 'abc中文' #