Debugged the Heuristic class