3 ms·
Instead of teaching them about function composition, recursion, data abstraction, and all the interesting concepts of computer science you end up teaching them
by cgag 12y ago
Instead of teaching them about function composition, recursion, data abstraction, and all the interesting concepts of computer science you end up teaching them a bunch of incidental stuff about memory locations and syntax.
Python suffers from this less than C, but still much more than Scheme. I really can't imagine advocating for something other than some dialect of scheme (maybe racket) for an intro undergraduate course.
For kids I can see choosing something like Javascript (as terrible as it is) just for the immediate feedback that someone before me mentioned.
- icebraining 12y agoMemory locations? In Python? I don't even know what you're saying.
- cgag 12y agoa = [1,2,3] b = a b += [1] => a == [1,2,3,1] a and b point to the same piece of memory even if you don't have to explicitly deal with pointers, you need to reason about them
- icebraining 12y agoYou just have to explain that "b = a" means that you're adding a new name to the thing/object named "a". Whether it's in the same memory location or not is an irrelevant implementation detail.
- na85 12y agoThese aren't computer science students. Most of them won't find recursion and data abstraction interesting in the slightest. If their primary interests were in computer science I'm sure they would have gone into a comp sci program. These students are there to learn programming as a tool to help them solve problems. The elegant recursive algorithm isn't really a goal they have. Their goal is to get a reasonable answer to a problem so they can move on with more important things.
- cgag 12y agoThat's fair if you're only doing a one semester for non-majors thing. I just saw "our undergraduates" and the debate about learning C and took it to mean starting a CS education with C. Those things I mentioned are how you solve problems though. What I was getting at is learning the low level details of how a computer, or at least C, works isn't problem solving.
- na85 12y ago>What I was getting at is learning the low level details of how a computer, or at least C, works isn't problem solving. Agree 100%