multiply
(self, n)
| 132 | return self.__class__(list(self) * n) |
| 133 | |
| 134 | def __imul__(self, n): |
| 135 | "multiply" |
| 136 | if n <= 0: |
| 137 | del self[:] |
| 138 | else: |
| 139 | cache = list(self) |
| 140 | for i in range(n - 1): |
| 141 | self.extend(cache) |
| 142 | return self |
| 143 | |
| 144 | def __eq__(self, other): |
| 145 | olen = len(other) |