Completed main recursive alg + helper methods, tests lacking