This program solves tetromino puzzles.
A tetromino is a shape made up of four squares, with each square connected along its sides. There are 5 different types of tetrominoes, as shown below:
- I-shaped tetromino
- L-shaped tetromino
- T-shaped tetromino
- O-shaped tetromino
- Z-shaped tetromino
oooo
o
ooo
o
ooo
oo
oo
oo
oo
The goal of the puzzle is to arrange the tetrominoes to fit into a specific shape, usually a rectangle. If two patterns are symmetrical or one can be rotated to match the other, they are considered identical.
This program offers three different types of puzzles:
The rectangle is a 4x2 grid. You can use two identical tetrominoes. This is the easiest puzzle in the repository.
The rectangle is a 4x4 grid. You can use two identical tetrominoes, but you must use at least three different types.
Use six L-shaped tetrominoes and form a rectangle.
- Install Ruby.
- Download the files.
- Run a terminal (a shell in Linux or Command Prompt in Windows).
- Type "ruby find4x2.rb" in your terminal.
- Do the same for "find4x4.rb" and "find6L.rb"