(self, key: int)
| 21 | cur.next = ListNode(key, value) |
| 22 | |
| 23 | def get(self, key: int) -> int: |
| 24 | cur = self.map[self.hashcode(key)].next |
| 25 | while cur and cur.key != key: |
| 26 | cur = cur.next |
| 27 | if cur: |
| 28 | return cur.val |
| 29 | return -1 |
| 30 | |
| 31 | def remove(self, key: int) -> None: |
| 32 | cur = self.map[self.hashcode(key)] |