ArthurBoucard / CPE_BSQ

algorithm which finds the biggest square in C

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

CodeFactor

BSQ

Epitech project :

Algorithm which finds the biggest square in C.


πŸ“ Map format description :

β€’ Its first line contains the number of lines on the board (and only that).
β€’ β€œ.” (representing an empty place) and β€œo” (representing an obstacle) are the only two characters for the other lines.
β€’ All of the lines are of the same length (except the first one).
β€’ It contains at least one line.
β€’ Each line is terminated by β€˜\n’.

Exemple of the map:

9
...........................
....o......................
............o..............
...........................
....o......................
..............o............
...........................
......o..............o.....
..o.......o................

πŸ’» How to run :

./bsq map.txt

Exemple of output :

.....xxxxxxx................
....oxxxxxxx................
.....xxxxxxxo...............
.....xxxxxxx................
....oxxxxxxx................
.....xxxxxxx...o............
.....xxxxxxx................
......o...............o.....
..o.......o.................

❗ Rules :

You can only read from the given files.
You have to represent only the biggest square. If they are several solutions, choose the square to the left.


Made in C

About

algorithm which finds the biggest square in C


Languages

Language:C 95.7%Language:Makefile 4.3%