Re:Multicore-enabling the N-Queens Problem Using Cilk++
by pmorici on Friday September 05, 2008 @01:13AM
(#295588)
He left out the most efficient solution. Using bits to store the positions instead of an array then you can check if the queens conflict with a couple bitwise &&'s instead of looping.
Re:Multicore-enabling the N-Queens Problem Using Cilk++
by threadman on Friday September 05, 2008 @08:23AM
(#295794)
TBB borrows the scheduling portion, but requires substantial code restructuring, and doesn't have a solution for the global variable problem analogous to Cilk's hyperobjects.