[Tutor] simple question about lists (original) (raw)
Lloyd Kvam pythonTutor at venix.com
Tue Jul 20 18:49:51 CEST 2004
- Previous message: [Tutor] simple question about lists
- Next message: [Tutor] simple question about lists
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
You should have no difficulty with multi dimensional lists.
board = [ [1,2,3],[4,5,6],[7,8,9] ] board[1][1] should reference the 5
I expect numeric would be overkill for this.
On Tue, 2004-07-20 at 12:22, Andy wrote: > Hello all, I'm getting ready to teach myself python. I'm going to > convert an old tic tac toe game I wrote in C to get my feet wet. One > question though, in C I could set up a multi dimensional array by > doing >> char board[3][3] >> I can't do multi dimensional lists in python can I? Am I right in > thinking that I would need to either use a one dimensional list or get > something like numeric to do this? Thanks in advance. >> -Andy > _________________________ > Tutor maillist - Tutor at python.org > http://mail.python.org/mailman/listinfo/tutor
Lloyd Kvam Venix Corp. 1 Court Street, Suite 378 Lebanon, NH 03766-1358
voice: 603-653-8139 fax: 801-459-9582
- Previous message: [Tutor] simple question about lists
- Next message: [Tutor] simple question about lists
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]