2-dimensional data structures

Grant Edwards grante at visi.com
Fri Jan 27 23:06:08 CET 2006

On 2006-01-26, Larry Bates <larry.bates at websafe.com> wrote:

>> I want to work on a sudoku brute-forcer, just for fun.
>> I am considering different strategies, but first I need to decide on the
>> data-structure to use for the progress/solution grid.
>> This being a square, I would have used a 9x9 2-dimensional array in my
>> teenage years back in the 80's, using BASIC.
>> What is the equivalent way to store data in python? - It isn't obvious
>> to me how to do it with lists.
>> 'scuse me for being thick - but give me a little pointer and I will do
>> the rest.
> Probably the numeric module:
> http://numeric.scipy.org/

I'd use numeric or numarray.  They have built-in notation for
grabbing a row or column.

Grant Edwards                   grante             Yow!  I appoint you
                                  at               ambassador to Fantasy
                               visi.com            Island!!!

More information about the Python-list mailing list