Re: [Computer-go] Bitwise-parallel surround capture

2014-05-25 Thread David Fotland
I never used paths. I keep a linked list of each point in the chain, and each stone has the index of the head of the list it is in. The board has an array of 361 list head/tail pointers, and an array of 361 root-indexes. Merging linked lists is O(1) since I keep a pointer to the last item.

Re: [Computer-go] Bitwise-parallel surround capture

2014-05-25 Thread Peter Drake
On Sun, May 25, 2014 at 11:05 AM, David Fotland fotl...@smart-games.comwrote: Merging linked lists is O(1) since I keep a pointer to the last item. You don't actually need that pointer, right? If a and b are chains, then you can just: temp = a.next; a.next = b.next; b.next = temp; (The