A moment's consideration will reveal that having a row of four of your stones, with blank spaces at each end, is a winning condition; no matter which end your opponent blocks, you will win by placing a stone at the other end.
The next step before that, obviously, is having an open row of three stones; this must be blocked, or it will develop into the open row of four.
The next step is to form two open rows of three, which share a common stone, which when placed, wins the game: your opponent can't block the formation of an open row of four stones.
Gomoku is played with many slight variations to the rules. A common variant is to require a row of exactly five stones for a win, longer rows (so-called overlines) not counting. The game is also now commonly played on a 15x15 board instead of the traditional 19x19. Another rule often used is the "rule of three and three", which says that you cannot form two open three-in-a-rows in the same move, even if such a move is required to block your opponent from winning.
Careful computer analysis by L. Victor Allis has shown that, at least on a 15x15 board, Black wins with perfect play. This applies whether or not overlines are considered as wins, but it assumes that the rule of three and three is not used.
The game of renju[?] is a variant played on a 15x15 board with a number of additional rules designed to make the game fairer. Ninuki-renju is a variant which adds capturing to the game; it was published in the USA in a slightly simplified form under the name Pente.
See also: Solved board games.