Re: [Edu-sig] what is a "variable" in Python?

2016-02-16 Thread kirby urner
I'm noticing that postings with edu-sig as one among several take longer to show up in the archives. I'm going to not reply-all in future and just use edu-sig for its mail reflector powers. That should make the moderator's job a little easier. Kirby On Tue, Feb 16, 2016 at 9:33 AM, kirby

Re: [Edu-sig] what is a "variable" in Python?

2016-02-16 Thread Mark Engelberg
Advanced students can gain a much deeper understanding of variables by writing an interpreter themselves. This free course on udacity will show advanced students how to write a basic Javascript interpreter in Python: https://www.udacity.com/courses/cs262

Re: [Edu-sig] what is a "variable" in Python?

2016-02-16 Thread Mark Engelberg
First, add me to the chorus of people saying that using the term "variable" to categorize mutable objects versus immutable objects is counter to the way every programmer uses and understands the term "variable" to mean a* name *that can take on multiple values over the lifetime of a program.

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread kirby urner
On Mon, Feb 15, 2016 at 8:48 PM, Andrew Harrington wrote: > I agree with Gary that mutability is a property of objects, not of > variables. > I think everyone who has put in two cents so far, including me, agrees with this point. The only rewording I might suggest is

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread Andrew Harrington
I agree with Gary that mutability is a property of objects, not of variables. An object has methods. A name does not - it can refer to an object with a particular method. I do not get the variable and remote buttons analogy at all. The importance of a variable naming a memory *location* with a

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread kirby urner
On Mon, Feb 15, 2016 at 5:23 PM, Carl Karsten wrote: > I think the point of this thread is: how important is this subject? > > I don't know that there's a scale of 1-10 answer. If / when it comes up, as a student question, it becomes important, but also instructors need

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread kirby urner
http://www2.engr.arizona.edu/~edatools/ece175/Lecture/python-variables.htm seems completely unobjectionable (forgive pun). The notion of a Python variable inherits from lamba x: x + 1 i.e. we don't specify the x and so map(lambda x: x + 1, [1, 2.0, Decimal(3)]) makes sense with all these

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread David MacQuigg
Seems like the difference is merely a matter of how we define the word "variable". Is it the label, or is it the object? I've always thought of it as being the label. Here is how I explained Python "variables" to engineering students (who were taking a class on C). Maybe I should have used the

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread kirby urner
No need to say "sorry" as if an honest disagreement were a cause for regret. I enjoy diversity. What would life be without different perspectives? Plain vanilla. I'm familiar with the mental model of which you speak and was for years myself not a Python programmer, with miles of source code to

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread Litvin
Sorry, I don't agree.  Thinking of variables as named containers is not an "incorrect mental model" but a useful metaphor for teaching programming to novices.  In my mental model, variable is called a "variable" because it can hold  different values at different times.  This has nothing to do

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread kirby urner
Perfect! That's exactly the right rant! Thank you Naomi. Python names are post-its, not buckets. You effectively counter the "bucket brigade". Hah hah. Here's me chatting with Steve Holden a few minutes ago, across many time zones (dinner time there, just getting to be lunch time here). ===

Re: [Edu-sig] what is a "variable" in Python?

2016-02-15 Thread Naomi Ceder
The short answer is that I agree with you. In fact, the link you shared is an example of my favourite incorrect mental model, which even prompted me to post this rant https://learnpython.wordpress.com/2015/05/21/notes-on-teaching-python-mental-models/ some months ago. TL;DR - "in Python

[Edu-sig] what is a "variable" in Python?

2016-02-15 Thread kirby urner
What do educators think about this discussion of variables in Python? http://www.python-course.eu/variables.php I find the "variable versus identifier" discussion, with repeated references to C / C++, to be somewhat on the confusing side. My view is "variable as container" makes sense if you're