SAT solver in C++