[Tutor] taking input for a list in a list
joel.goldstick at gmail.com
Mon Sep 26 15:08:05 CEST 2011
On Mon, Sep 26, 2011 at 8:46 AM, surya k <suryak at live.com> wrote:
> Actually my programming language is C.. learning python.
> I'm trying to write sudoku program for which I need to take input.
> This is what I did merely
> *list = 
> for i in range (0,4) :
> for j in range (0,4) :
> list[i][j].append (" int (raw_input("Enter") ) )
> This is completely wrong.. but I couldn't handle this kind of.. how do I..
> Actually I need a list in a list to handle sudoku.
> for a simple list to get input.. this would obviously work..
> *list.append ( int(raw_input("Enter") )*
> Can you tell me how do I do this correctly ?
> Tutor maillist - Tutor at python.org
> To unsubscribe or change subscription options:
> because list is a built in data type you should name your list something
else. What does your code do? does it give traceback errors? After you
change list to, say my_list what do you get?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Tutor