Let three numbers x-y-z describe the game state by giving the number of spaces between the pawns. For example, at the start of the game the game state is 6-6-6. There are two basic "always win" options the computer player is going for after its moves:
a) n-n-0, where n is any number. (Note that this is the reason to prohibit players from moving past the half-way mark at the beginning of the game; otherwise, the first move would be to collapse a column immediately to bring the game to 6-6-0.) After reaching this state, you merely mirror the opponent's moves.
b) 3-2-1. This is another scenario that you can always win from, because whatever your opponent does, you can create either a 2-2-0 or a 1-1-0 from it.
It is not possible to beat the player that moves first. This appears to be the most "defensive" sequence that the AI will follow when you move first:
Code:
You AI
6-6-4 6-4-3
6-4-2 5-4-2
5-4-1 5-3-1 (Gotcha!)
3-2-1
This has created one of the simple winning scenarios. The remainder of the game, for completeness:
Code:
3-2-1 2-2-1
2-2-0 2-1-0
1-1-0 1-0-0
0-0-0
Interesting puzzle. :)