module documentation

Undocumented

Function check Undocumented
Function revword Undocumented
Function step Undocumented
Function word_finder Undocumented
Function wordfinder Attempt to arrange words into a letter-grid with the specified number of rows and columns. Try each word in several positions and directions, until it can be fitted into the grid, or the maximum number of allowable attempts is exceeded...
def check(word, dir, x, y, grid, rows, cols): (source)

Undocumented

def revword(word): (source)

Undocumented

def step(word, x, xf, y, yf, grid): (source)

Undocumented

def word_finder(): (source)

Undocumented

def wordfinder(words, rows=20, cols=20, attempts=50, alph='ABCDEFGHIJKLMNOPQRSTUVWXYZ'): (source)

Attempt to arrange words into a letter-grid with the specified number of rows and columns. Try each word in several positions and directions, until it can be fitted into the grid, or the maximum number of allowable attempts is exceeded. Returns a tuple consisting of the grid and the words that were successfully placed.

Parameters
words:listthe list of words to be put into the grid
rows:intthe number of rows in the grid
cols:intthe number of columns in the grid
attempts:intthe number of times to attempt placing a word
alph:listthe alphabet, to be used for filling blank cells
Returns
tupleUndocumented