change Position and Polynomio structs (less memory usage)
Some checks failed
Linux arm64 / Build (push) Failing after 2m9s
Some checks failed
Linux arm64 / Build (push) Failing after 2m9s
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
class Polyomino {
|
||||
private:
|
||||
std::set<Position> positions; // the squares composing the polyomino, (0,0) is downleft
|
||||
int length; // the size of the smallest square box in which the polyomino can fit on any rotation
|
||||
std::int8_t length; // the size of the smallest square box in which the polyomino can fit on any rotation
|
||||
|
||||
public:
|
||||
/**
|
||||
@@ -24,7 +24,7 @@ class Polyomino {
|
||||
/**
|
||||
* Creates a polyomino with the specified positions and length, wheter it is actually a polyonimo of this length is not checked
|
||||
*/
|
||||
Polyomino(const std::set<Position>& positions, int length);
|
||||
Polyomino(const std::set<Position>& positions, std::int8_t length);
|
||||
|
||||
/**
|
||||
* Translates the polyomino to the lowest unsigned values (lower row on y = 0, and left-most column on x = 0)
|
||||
|
||||
Reference in New Issue
Block a user