2-SatSolver
Java
★ 0
updated 8y ago
2-SAT is a classic computational problem of assigning Boolean values (true or false) to satisfy a system of constraints operating on pairs of variables. Though Boolean satisfiability problems are generally NP-complete, 2-SAT problems are a special instance of Boolean satisfiability problems that can be solved in linear time. I have used Kosaraju’s algorithm to solve the 2-SAT problem where the implementation has a linear time complexity and linear space complexity.
No plain-English explanation yet — one is being written right now. Check back in a minute.