What other languages use the same data model as Python?
harrismh777
harrismh777 at charter.net
Mon May 9 17:28:43 EDT 2011
Gregory Ewing wrote:
>
> +-------------+
> +---+ | |
> a | --+---------------->| |
> +---+ | |
> +-------------+
> ^
> +---+ |
> b | --+-----------------------|
> +---+
>
> In this model, a "reference" is an arrow. Manipulating references
> consists of rubbing out the arrows and redrawing them differently.
Greg, this is an excellent model, thank you for taking the time to
put it together for the list... very helpful.
Both Summerfield and Lutz use the same model (and almost the
identical graphic symbolism) to explain dynamic typing in Python.
Summerfield's Programming in Python 3 2nd ed. has a good explanation
similar, see pages 17 and 32 (there are others). Lutz has an entire
chapter devoted to the topic in Learning Python 4th ed., see chapter
six. He calls it the Dynamic Typing Interlude.
The model is in-the-field and very workable; and yet, it does have
limitations, as most models do. For visual thinkers this model probably
comes closest to being most helpful, esp in the beginning.
kind regards,
m harris
More information about the Python-list
mailing list