Skip to content

Commit 50e0c39

Browse files
committed
Kruskal, first draft
1 parent 4ee274e commit 50e0c39

File tree

6 files changed

+207
-422
lines changed

6 files changed

+207
-422
lines changed

src/algorithms/controllers/TTFTreeInsertion.js

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,12 @@ export default {
316316
},
317317

318318
initTree(chunker, value, tree) {
319-
chunker.add('T234_Insert(t, k)');
319+
// initially say tree is empty to avoid confusion
320+
chunker.add('T234_Insert(t, k)',
321+
(vis) => {
322+
vis.tree.setFunctionName('Tree is Empty');
323+
vis.tree.setText(``);
324+
});
320325
chunker.add('if t = Empty',
321326
(vis) => {
322327
vis.tree.setFunctionName('T234_Insert');

0 commit comments

Comments
 (0)