Re: [Tutor] Tkinter grid question

2017-04-07 Thread Alan Gauld via Tutor
On 07/04/17 11:08, Phil wrote: > ...In this case I become confused because had expected [][] > to be the same as a C two dimensional array. It is, sort of. If you set the data up correctly to start with :-) -- Alan G Author of the Learn to Program web site http://www.alan-g.me.uk/

Re: [Tutor] Tkinter grid question

2017-04-07 Thread Phil
On Fri, 07 Apr 2017 10:01:21 +0200 Peter Otten <__pete...@web.de> wrote: > > e = [None] * 6 , [None] * 2 > > In the above line you are creating a 2-tuple consisting of two lists: > > >>> [None]*6, [None]*2 > ([None, None, None, None, None, None], [None, None]) > > What you want is a list of

Re: [Tutor] Tkinter grid question

2017-04-07 Thread Phil
On Fri, 7 Apr 2017 10:08:40 +0100 Alan Gauld via Tutor wrote: > Peter has already answered the problem but I'd like > to point out how he used the interactive prompt >>> to > demonstrate what was going wrong. Thank you Alan. The >>> prompt, print() and Duckduckgo do get a good

Re: [Tutor] Tkinter grid question

2017-04-07 Thread Alan Gauld via Tutor
On 07/04/17 03:09, Phil wrote: > Thank you for reading this. > > This is my first attempt at using Tkinter and I've quickly run into a problem. > Peter has already answered the problem but I'd like to point out how he used the interactive prompt >>> to demonstrate what was going wrong. You

Re: [Tutor] Tkinter grid question

2017-04-07 Thread Peter Otten
Phil wrote: > Thank you for reading this. > > This is my first attempt at using Tkinter and I've quickly run into a > problem. > > If e is a one dimensional list then all is OK and I can delete and insert > entries. The problem comes about when the list is made two dimensional, as > follows: >

[Tutor] Tkinter grid question

2017-04-07 Thread Phil
Thank you for reading this. This is my first attempt at using Tkinter and I've quickly run into a problem. If e is a one dimensional list then all is OK and I can delete and insert entries. The problem comes about when the list is made two dimensional, as follows: from tkinter import *