NAME

Game::WordBrain::Solution - Representation of Potential WordBrain Solution

SYNOPSIS

my @words = (
    Game::WordBrain::Word->new( ... ),
    Game::WordBrain::Word->new( ... ),
    ...
);

my $solution = Game::WordBrain::Solution->new({
    words => \@words,
});

DESCRIPTION

For any Game::WordBrain there are multiple possible solutions. A solution is defined as an ordered collection of words ( ArrayRef of Game::WordBrain::Word ).

NOTE Each of these solutions is just a potential solution and may not be *THE* solution that WordBrain is looking for. The only way to know for sure is to try the solution.

ATTRIBUTES

words

ArrayRef of Game::WordBrain::Words

METHODS

new

my @words = (
    Game::WordBrain::Word->new( ... ),
    Game::WordBrain::Word->new( ... ),
    ...
);

my $solution = Game::WordBrain::Solution->new({
    words => \@words,
});

Given an ArrayRef of Game::WordBrain::Words, returns a Game::WordBrain::Solution.