Kirby said:
We say reference a lot when talking about a variable's relationship
to a piece of memory. I'm thinking handle could be used more
(optionally -- this is not an instruction) and we could even show a
coffee cup (doesn't have to be coffee -- a mug) with two handles, when
explaing
The coffee-cup-handle metaphor is certainly useful, but IMHO not quite as
spot-on as the sticky-note metaphor.
-John Posner
Excellent review John thanks.
Below is the kind of thing a teacher could project.
IDLE 1.2b2
handle1 = ['coffee','sugar','cream']
handle2 = handle1
id(handle1)
Just saw this on the europython list :-- Forwarded message --From: Harald Armin Massa [EMAIL PROTECTED]
Date: 02-Oct-2006 21:15Subject: [EuroPython] Children first and a hole-in-the-wallTo: europython@python.org
europython@python.orgHello,all who were fascinated by the children
On Mon, 2006-10-02 at 10:00 -0700, kirby urner wrote:
handle1 = ['coffee','sugar','cream']
handle2 = handle1
id(handle1)
13645944
id(handle2)
13645944
I always thought that when presenting this it is natural and important -
in order for the student to truly get it - to do an as
kirby urner wrote:
We say reference a lot when talking about a variable's relationship
to a piece of memory. I'm thinking handle could be used more
(optionally -- this is not an instruction) and we could even show a
coffee cup (doesn't have to be coffee -- a mug) with two handles, when
I'm catching up here, and just read the namespaces thing --
How about namespaces are like card catalogs in a closed stack library.
At the Library of Congress (here in the U.S.), up through when I last
went (some time ago), any U.S. citizen can go in and find a book in a
catalog (I'm certain
(Fully aware of the potential problems of quoting out of context and
of the limitation of using analogies...)
On 10/2/06, Scott David Daniels [EMAIL PROTECTED] wrote:
I'm catching up here, and just read the namespaces thing --
How about namespaces are like card catalogs in a closed stack
Anyway, I would advocate the as opposed to be integrated into such a
presentation.
Art
Yes, once bitten in the butt by the fact of a two handled mug, then
comes the question: so how do I make sure each handle gets a mug to
itself? (as in why should we share the same beer?).
At this point,
Am 03.10.2006 um 00:47 schrieb kirby urner:
This metaphor may be good for references, but not for Python. You
are
left with the intuition that you can look at the mug and enumerate
the
handles. Maybe a an object is a living thing with lasers shining
on it
(referring to it), that
On Mon, 2006-10-02 at 16:04 -0700, kirby urner wrote:
Anyway, I would advocate the as opposed to be integrated into such a
presentation.
Art
Actually *duplicating* a piece of memory (wasteful?), to make the same
contents reside elsewhere (why?), with its own handles, is considered
a
On 10/2/06, Arthur Siegel [EMAIL PROTECTED] wrote:
The argument I keep making and for which I cannot seem to find any
takers, is that essential to explaining/understanding assignment of a
list to a name, is understanding in the negative - i.e., what it is not.
We are still just teaching basic
On Mon, 2006-10-02 at 16:04 -0700, kirby urner wrote:
Or we might import the copy module.
Or we might take the whole thing as a slice i.e. newlist = oldlist[:].
I used the list(handle1) alternative purposefully, based on Alex
Martelli's position on the matter.
The first time I heard him
interesting to:
http://www.greenstar.org/butterflies/Hole-in-the-Wall.htm
An experiment worth doing once I suppose. Proves kids have natural
ability that we mostly waste and squander.
They deserve real opportunities though, not holes in the wall. Just
like a Physicist to coldly treat them
kirby urner wrote:
Scott mentioned our not being able to see how many handles a mug has,
but with the sys module we can:
Perhaps I said that, but what I _meant_ was that you could see the
handles. In my mind, at least, there is a huge difference between
seeing the handles (what is this
14 matches
Mail list logo