Implementation of DPLL algorithm