Runtime: faster than 95.18%. Memory Usage: less than 100.00%  Python3 hashmap
\nclass SnapshotArray:\n\n    def __init__(self, length: int):\n        self.data = {}\n        self.ver = 0\n        self.data[self.ver] = {}\n\n    def set(se
```\nclass SnapshotArray:\n\n    def __init__(self, length: int):\n        self.data = {}\n        self.ver = 0\n        self.data[self.ver] = {}\n\n    def set(self, index: int, val: int) -> None:\n        self.data[self.ver][index] = val\n\n    def snap(self) -> int:\n        self.ver += 1\n        self.data[self.ver] = self.data[self.ver - 1].copy()\n        return (self.ver - 1)\n        \n    def get(self, index: int, snap_id: int) -> int:\n        # print(self.data)\n        return self.data[snap_id].get(index, 0)\n```
['Python3']