8000 GitHub - Jeff-Gillot/word-clique
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Jeff-Gillot/word-clique

Repository files navigation

Five words clique

It's a try at solving the 5 word clique more efficiently than the proposed solution.

See the video that explains the problem: https://www.youtube.com/watch?v=_-AfhLQfb6w

To run you need java installed

linux & mac
./gradlew run

windows
./gradlew.bat run

The solution is fast < 2 seconds because it takes a different approach.

Instead of testing all possibilities, we can discard rapidly the solutions that won't work as soon as possible.
We use the fact that we know we need 25 of the 26 letters in each valid solution.
Because of that we can try to fill all letters one by one, and once we have more than one letter missing, we discard the solution.
It still uses the graph theory, but because we are able to remove most of the options asap we have much less combinations to test.

You can find more technical info in the Main.kt.

It also makes use of a bitset representation of the words, but that doesn't make much of a difference.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

0