python-master
python从菜鸟到大佬的进阶之路
ReLuJie
计算机视觉.
展开
-
python可迭代对象排序
1111原创 2021-05-31 22:33:16 · 205 阅读 · 0 评论 -
collections模块详解
collections模块高性能数据结构 针对python的基础容器{dict,list,set, andtuple}进行特殊的优化,来产生更具针对性的高性能容器!Counter {dict-subclass } deque { a generalization of stacks and queues } defaultdict { a subclass of the built-indictclass...原创 2020-09-17 23:02:06 · 197 阅读 · 0 评论 -
python 类方法之 __repr__() vs __str__()
Demofrom math import hypotclass Vector: def __init__(self, x=0, y=0): self.x = x self.y = y def __repr__(self): # if u don't define, class use the default __repr__() # and print(“classname + object at + ip_a.原创 2020-09-16 23:02:38 · 170 阅读 · 0 评论