Edited the function solveTimeTabling()