Re: [Tutor] sample dictionairies

2015-04-19 Thread Alan Gauld
On 19/04/15 02:56, Jim Mooney wrote: Where could I download Python sample dictionaries on different subjects. Like Ben I don't understand what you mean by subject. However,... They're hard to type and I can only do small, limited ones to practice with. If you just want a large dictionary

Re: [Tutor] sample dictionairies

2015-04-19 Thread Steven D'Aprano
On Sat, Apr 18, 2015 at 06:56:41PM -0700, Jim Mooney wrote: Where could I download Python sample dictionaries on different subjects. They're hard to type and I can only do small, limited ones to practice with. I don't think you can download Python dicts. It would be a bit hard, since Python

Re: [Tutor] lists, name semantics

2015-04-19 Thread Dave Angel
On 04/19/2015 12:07 AM, boB Stepp wrote: . Before Peter changed one of these changeable objects, he had: a = [1, [x, y], 3] b = a[:] Now BOTH a[1] and b[1] now identify the location of the inner list object, [x, y] . Apparently, Python, in its ever efficient memory management fashion,

[Tutor] sample dictionairies

2015-04-19 Thread Jim Mooney
Where could I download Python sample dictionaries on different subjects. They're hard to type and I can only do small, limited ones to practice with. -- Jim The probability of a piano falling on my head is 50%. After it falls on my head the probability is 100%. My confidence in the piano

Re: [Tutor] sample dictionairies

2015-04-19 Thread Ben Finney
Jim Mooney cybervigila...@gmail.com writes: Where could I download Python sample dictionaries on different subjects. I don't know what yoy mean by the “subject” of a dictionary. A Python dict is a data structure. Its values can be any collection of Python objects. Is the “subject” of a

Re: [Tutor] sample dictionairies

2015-04-19 Thread Laura Creighton
In a message of Sat, 18 Apr 2015 18:56:41 -0700, Jim Mooney writes: Where could I download Python sample dictionaries on different subjects. They're hard to type and I can only do small, limited ones to practice with. -- Jim For randomly generating data which look like addresses, I use:

Re: [Tutor] lists, name semantics

2015-04-19 Thread Dave Angel
On 04/19/2015 03:08 PM, boB Stepp wrote: On Sun, Apr 19, 2015 at 6:47 AM, Dave Angel da...@davea.name wrote: On 04/19/2015 12:07 AM, boB Stepp wrote: [...] I hope this is helpful, and, if there are any misstepps, that when they are revealed both of our understandings will be enhanced!

Re: [Tutor] lists, name semantics

2015-04-19 Thread Joel Goldstick
On Sun, Apr 19, 2015 at 6:23 PM, boB Stepp robertvst...@gmail.com wrote: On Sun, Apr 19, 2015 at 4:05 PM, Dave Angel da...@davea.name wrote: On 04/19/2015 03:08 PM, boB Stepp wrote: Or is the real point that we are adding an abstraction layer so we don't even have to think about where

Re: [Tutor] lists, name semantics

2015-04-19 Thread Laura Creighton
In a message of Sun, 19 Apr 2015 17:23:13 -0500, boB Stepp writes: On Sun, Apr 19, 2015 at 4:05 PM, Dave Angel da...@davea.name wrote: abstract, and the details are unimportant to the user. For example, the jython system does not use addresses at all. And an object gets moved around from time

Re: [Tutor] lists, name semantics

2015-04-19 Thread boB Stepp
On Sun, Apr 19, 2015 at 12:24 AM, Cameron Simpson c...@zip.com.au wrote: On 19Apr2015 15:09, Cameron Simpson c...@zip.com.au wrote: On 18Apr2015 23:26, boB Stepp robertvst...@gmail.com wrote: On Sat, Apr 18, 2015 at 11:08 PM, Cameron Simpson c...@zip.com.au wrote: [...] Two problems often

Re: [Tutor] lists, name semantics

2015-04-19 Thread boB Stepp
On Sun, Apr 19, 2015 at 6:47 AM, Dave Angel da...@davea.name wrote: On 04/19/2015 12:07 AM, boB Stepp wrote: [...] I hope this is helpful, and, if there are any misstepps, that when they are revealed both of our understandings will be enhanced! Some of your knowledge of other languages is

Re: [Tutor] lists, name semantics

2015-04-19 Thread Dave Angel
On 04/19/2015 06:28 PM, Joel Goldstick wrote: On Sun, Apr 19, 2015 at 6:23 PM, boB Stepp robertvst...@gmail.com wrote: On Sun, Apr 19, 2015 at 4:05 PM, Dave Angel da...@davea.name wrote: On 04/19/2015 03:08 PM, boB Stepp wrote: Or is the real point that we are adding an abstraction layer

Re: [Tutor] lists, name semantics

2015-04-19 Thread Laura Creighton
In a message of Sun, 19 Apr 2015 19:19:27 -0400, Dave Angel writes: Good answer. The java jvm garbage collector is free to move blocks around to defrag the free space. Correct. FWIW, I'm told the ID value used is a simple integer, that indexes a list containing the actual addresses. Also

Re: [Tutor] lists, name semantics

2015-04-19 Thread Laura Creighton
In a message of Sun, 19 Apr 2015 17:23:13 -0500, boB Stepp writes: The last sentence in this paragraph has me intrigued. Why would an object, once it has been created, be moved? What practical benefit does doing this give? boB If you have more than enough memory in your system, you never do this

Re: [Tutor] lists, name semantics

2015-04-19 Thread Alan Gauld
On 20/04/15 00:29, Laura Creighton wrote: So in this case, the binding value is an integer, not an address. Utterly wrong. The binding value has to be an address. I think it depends on how you define 'binding' value. In Python binding is the connection between a name and an object. So in a

Re: [Tutor] lists, name semantics

2015-04-19 Thread boB Stepp
On Sun, Apr 19, 2015 at 4:05 PM, Dave Angel da...@davea.name wrote: On 04/19/2015 03:08 PM, boB Stepp wrote: Or is the real point that we are adding an abstraction layer so we don't even have to think about where objects are physically stored in RAM? Somebody keeps track, but the address

Re: [Tutor] =Linked List Using Map

2015-04-19 Thread Alan Gauld
On 19/04/15 16:25, niyanax...@gmail.com wrote: May you take a look and let me know what needs to be changed? Thank you in advance. The node code looks OK. class Map: Read through your init method, remembering that it only gets calledv once when the Map is created. def __init__(

[Tutor] OT: Is there a good book that covers the history/evolution of software? [Inspired by the thread: lists, name semantics]

2015-04-19 Thread boB Stepp
In the beginning (I assume.) there was machine code and only machine code. And I imagine this was not very good. Then I assume the next step was assembler, which probably only moderated the (then) tedium of coding. Then real high level languages were started to be developed, and this was very

Re: [Tutor] OT: Is there a good book that covers the history/evolution of software? [Inspired by the thread: lists, name semantics]

2015-04-19 Thread Joel Goldstick
On Sun, Apr 19, 2015 at 9:03 PM, boB Stepp robertvst...@gmail.com wrote: In the beginning (I assume.) there was machine code and only machine code. And I imagine this was not very good. Then I assume the next step was assembler, which probably only moderated the (then) tedium of coding. Then

[Tutor] How to close a Tkinter window from a different thread?

2015-04-19 Thread boB Stepp
I am not certain that my terminology is correct in the subject line. Let me explain my issue. Scenario A: 1) I start out inside a commercial software environment (Abbreviated CSA henceforth). 2) I initiate a script in the CSA's scripting language. 3) This script calls an external Python

Re: [Tutor] =Linked List Using Map

2015-04-19 Thread niyanaxx95
Thank You Steven for your great help You really helped me to understand my assignment more as well as what maps and linked lists are. I used your guidance and came up with my full code. May you take a look and let me know what needs to be changed? Thank you in advance. class Node: