This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Format: HTML | |
max tokens | |
50000 | |
All Extensions | |
Base path: root | |
±17015 tokens | |
Copy |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Value: | |
def __init__(self, data: int, label: str, _children = (), _op: str = ""): | |
self.data = data | |
self.label = label | |
self._children = set(_children) | |
self._op = _op | |
def __repr__(self) -> str: | |
return f"Value({self.label}, data={self.data})" | |