![]() ![]() To imagine what constitutes a valid word candidate, we can pretend the player started at the top left, position (0, 0) by convention, and connected letters to form the path below. In reality, the letters are randomly drawn, but this ordered look will help us follow the algorithm later. The 4-by-4 toy board above is a (poor) example of a game. The sequence grows astonishingly fast! You can see for yourself at the Online Encyclopedia of Integer Sequences number A236690. For interest, the number of paths on the board is fixed, given N, and we know up to a 10-by-10 grid. ![]() These terms come from Graph Theory, but it’s not required at all to understand the problem and this solution. And King graph, or King grid, because valid moves are the same as the King in a game of chess. Directed, meaning direction matters beginning to end. Mathematically, the algorithm finds every simple, directed path on an N-by-N King graph. Boggle Solver employs a recursive algorithm for first finding every possible path on the board, and then checking if the word it forms is in a dictionary. ![]()
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |