Skip to content

Four in a Row

Drop a disc. Think three moves ahead.

Controls · Click a column, or use arrow keys and Enter

Streak0
Best0
W / L / D0/0/0

About Four in a Row

Four in a Row is a solved game with a deceptively small rule set: drop a disc into one of seven columns, it falls to the lowest free slot, and the first player to line up four in any direction wins. Gravity is the whole difficulty — you cannot place a disc where you want it, only above whatever is already there.

The computer opponent here uses a real search, looking several moves ahead and scoring the positions it finds rather than picking greedily. On Hard it will punish a careless move immediately, and it will happily build two threats at once so that blocking one loses to the other. Going first is a genuine advantage; use it.

How to play

  1. Click a column to drop your disc into it, or move with the arrow keys and press Enter.
  2. Discs fall to the lowest empty slot in that column.
  3. Line up four of your discs horizontally, vertically or diagonally to win.
  4. The board holds 42 discs. If it fills with no line of four, the game is a draw.
  5. Pick Easy, Medium or Hard to change how many moves ahead the computer looks.

Five tips that actually move your score

  • Take the centre column first. More winning lines pass through the middle than anywhere else, and controlling it roughly doubles your options for the rest of the game.
  • Count the parity of your threats. On a seven-by-six board, the player going first wins on odd rows and the second player on even rows. Building a threat on the wrong row hands your opponent the tempo.
  • Build two threats, not one. A single line of three is always blocked. Two lines of three that complete on the same square are unstoppable — that double threat is how nearly every real win happens.
  • Never play directly under an opponent's winning square. Filling that slot hands them the win on their next turn. Check what your move sets up above it before you commit.
  • Block late, not early. Reacting to every three the computer builds lets it dictate the whole game. Only block when the threat is actually live.

Frequently asked questions

How strong is the computer?
Easy looks two moves ahead, Medium four, and Hard six with alpha-beta pruning and positional scoring. Hard is a genuine challenge for most players.
Who goes first?
You do, every game. On a seven-by-six board the first player has a theoretical forced win, so the advantage is real.
What does the win streak track?
How many games you have won in a row against the computer without losing or drawing. It resets on any non-win.
Can the game end in a draw?
Yes, if all 42 slots fill without either side making four in a row. It is uncommon but it happens.
Keep playing

More games like this