Zinc233
-
【Python】笔记:序列的修改、散列和切片
序列的修改、散列和切片 from array import array import reprlib, math, numbers from functools import reduce from operator import xor from itertools import chain # Vector_v1 class Vector: typeco…
-
【Python】笔记:接口:从协议到抽象基类
S11 接口:从协议到抽象基类 # random.shuffle 就地打乱 from random import shuffle l = list(range(10)) shuffle(l) print(l) shuffle(l) print(l) [0, 6, 3, 2, 4, 8, 5, 7, 1, 9] [0, 5, 9, 7, 6, 2, 4, 8,…