MCPcopy Create free account
hub / github.com/codemistic/Data-Structures-and-Algorithms / __init__

Method __init__

Python/HuffmanCodingAlgo.py:4–14  ·  view source on GitHub ↗
(self, freq, symbol, left=None, right=None)

Source from the content-addressed store, hash-verified

2
3class node:
4 def __init__(self, freq, symbol, left=None, right=None):
5
6 self.freq = freq
7
8 self.symbol = symbol
9
10 self.left = left
11
12 self.right = right
13
14 self.huff = ''
15
16 def __lt__(self, nxt):
17 return self.freq < nxt.freq

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected