solution to csp problems