DONE COMMIT. 4.1. 4.2. treeSearch and folding