Skip to content

Latest commit

 

History

23 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

fillit

Project written in collaboration with Diana Boudy

Fillit is a simple program that takes a bunch of tetris blocks in text format, and tries to arrange them in the smallest square possible.

We used recursive backtracking to solve this, we believe it was appropriate as we also needed to place the top blocks of the file in the upper-left corner first when multiple arragements are possible.

File format :

Each block must be separated by at least one empty line.

A block fits into a 4x4 square of [.] (empty spaces) with [#] representing parts of the block.

Examples :

#...
#...
#...

....
.##.
.##.
....

..##
...#
...#
....

Only valid tetris blocks are allowed.

About

laying tetris pieces in a square

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages