[Tutor] I am reading the tutorial alright?

elis aeris hunter92383 at gmail.com
Mon Mar 24 00:16:29 CET 2008


in c++ i use array[n][n] to store things.

how do i create an array like that?





On Sun, Mar 23, 2008 at 4:13 PM, bob gailer <bgailer at alum.rpi.edu> wrote:

> elis aeris wrote:
> > t = 12345, 54321, "hello!"
> > print t[0]
> >
> > the way the 3 items are saved and access fits my need, now how do I
> > make t have more than one entry so effectively I get this?
> >
> > t[n][n]
> >
> (1) are you going through the tutorials as requested?
> (2) please learn how to ask meaningful questions
> For example t[n][n] does not communicate the outcome you desire.
> In Python t[n][n] would get you the nth element of the nth element of t.
> For example if n were 2 you'd get 3. If that is what you want you just
> answered your own question, as a simple test in the Python interactive
> window would reveal.
>
> Otherwise we can only guess as to what you want and that wastes all of
> our time!
>
> It would be far more effective to show us what the result would look
> like based on the data you entered into t.
>
> PLEASE do as much as you can to solve problems yourself and express
> questions CLEARLY!
>
> --
> Bob Gailer
> 919-636-4239 Chapel Hill, NC
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20080323/0f6cbcb6/attachment.htm 


More information about the Tutor mailing list