Стрельников Алексей, 617 UniSize 13372
Демихов Валентин, 611 группа UniSize 13607
f1def sizer(cls):f1def sizer(cls):
22
n3    class Size:n3    class SizeDescriptor:
44
t5        def __get__(self, obj, cls):t5        def __get__(self, instance, cls):
6            if hasattr(obj, '__len__'):6            if hasattr(instance, '__len__'):
7                return len(obj)7                return len(instance)
8            elif hasattr(obj, '__abs__'):8            elif hasattr(instance, '__abs__'):
9                return abs(obj)9                return abs(instance)
10            else:
11                return 010            return 0
12    cls.size = Size()11    cls.size = SizeDescriptor()
13    return cls12    return cls
Legends
Colors
 Added 
Changed
Deleted
Links
(f)irst change
(n)ext change
(t)op