A bin-packing algorithm to fit Tetris pieces into a box, using recursive backtracking. Bitwise implementations.
Creator: Pedago Team. Task description
The purpose is to make the smallest possible "square" (which can contain holes) with a given list of tetriminos(tetris pieces), but the disposition must be as such that it returns the first possible solution when placing them recursively from the top left.
Download and compile repo:
git clone https://github.com/IvanKozlov95/fillit
cd fillit
make
Executable fillit
will be created. Usage:
./fillit [file]
There are some example files in sample
folder for you to try it out.
./fillit samples/test_8
.AABB..
AACCB..
.CC.BDD
.EE.DD.
EEFFGG.
.FFGGHH
....HH.
This project was developed jointly by Ivan Kozlov @ivankozlov95 and Marc G Tan @mgia
This project is licensed under the GNU General Public License 3.