Why Did M.I.T. Switch from Scheme to Python?
I’ve been seeing mail and blog postings, particularly from people in the Lisp community, why MIT has switched from using Scheme to Python in the freshman core curriculum for the department of Electrical Engineering and Computer Science.
At the International Lisp Conference, Prof. Gerry Sussman gave a short impromptu talk explaining the new freshman curriculum. Just to get a second opinion, I later called Prof. Jacob White, one of the designers of the curriculum and lecturers for the core courses. (Digression: Jacob and I have been close friends since I was six years old!) He confirmed Gerry’s description.
Asking why they changed languages is, in some sense, the wrong question.
The freshman software engineering course, since 1985, has been based on the book Structure and Interpretation of Computer Programs (known as SICP), which uses Scheme. The course is now nearly thirty years old. Engineering has changed quite a lot in thirty years. Since 1995, Gerry and his co-author Prof. Hal Abelson have advocated changing the freshman curriculum radically, not basing it on SICP.
In 1980, computer engineering was based on starting with clearly-defined things (primitives or small programs) and using them to build larger things that ended up being clearly-defined. Composition of these fragments was the name of the game.
However, nowadays, a real engineer is given a big software library, with a 300-page manual that’s full of errors. He’s also given a robot, whose exact behavior is extremely hard to characterize (what happens when a wheel slips?). The engineer must learn to perform scientific experiments to find out how the software and hardware actually work, at least enough to accomplish the job at hand. Gerry pointed out that we may not like it this way (“because we’re old fogies”), but that’s the way it is, and M.I.T. has to take that into account.
The new approach also has the big advantage that it combines computer science with electrical engineering, whereas the old one taught them as entirely separate disciplines. This way, students see how they interrelate. Also, as Jacob points out, some of the same macro-principles apply to both software and hardware, and the students see this illustrated. There is extensive lab work, making robots and mobile applications.
It just so happens that the robotics substrate software that comes with the system they’re using is programmed in Python. Similarly, the mobile software environment is based on Python. (Or, at least, the original plan was to use such a substrate, although it may have changed for various business reasons.)
Changing programming languages was absolutely not a goal of the curriculum change. It was merely the result of the consequences of various decisions. We can always discuss how it came to be that the robots and mobile devices are using Python instead of some other language, but that’s not the question being addressed here. M.I.T. has nothing against Scheme. (And, of course, M.I.T. does teach classic software engineering, later in the curriculum.)
![Reblog this post [with Zemanta]](http://img.zemanta.com/reblog_e.png?x-id=16c4697e-0162-4e85-ac13-b671a11e63c0)
May 10th, 2009 at 10:36 am
Let me start by saying that for the last 30 years, about three four times a year, I’ve wished I could have come into comp. sci. by the SICP door.
The above is as good a story as any, but I think the it leaves unsaid some stuff. The obvious one is the s-exprs have yet to win in the marketplace of ideas and commerce and that alone creates a vector force against the course. But more interesting, to me, is that the course presumed something about computer science that isn’t true, and wasn’t true at the time.
SICP reflected an aspiration to place computer science closer to the pure sciences, i.e. math. You write: “However, nowadays … engineer must learn to perform scientific experiments to find out how the software and hardware actually work” is true, but for the one word “nowadays.’ That has always been the case. CS is also an engineering discipline, and a branch of natural science. This is why it’s alpha-citizens are hackers, not mathematicians.
Even in 1965 (a decade before SICP), when I came into the field CS was already all the above, science, engineering, natural science. Most of the most interesting things I learned over the years came from toying with, taking apart, and putting back together systems like Simula, Forth, Focal, L*, Multic, Macsyma, the time sharing system at Dartmoth, etc. etc. When I finally came to meet the folks who self identified as Computer Scientists I was overwhelmingly struck by their blindness. Blind on the one hand to the wealth of examples waiting to be studied. And blind to how codifying the rules of the emerging science was repeatedly undone by the shifting landscape of the technology.
SICP is a beautiful thing, but among it’s flaws was an intentional and studied blindness to the issues you suggest the new course addresses. So at least for those reasons it’s a good shift.
But wait, their’s more! What has changed in the last 30+ years is that computer science is now also a social science, and probably a statistical one. Maybe they will fix that in a decade or too
.
May 10th, 2009 at 1:30 pm
popurls.com // popular today…
story has entered the popular today section on popurls.com…
May 10th, 2009 at 1:30 pm
“CS is also an engineering discipline [...]“.
That’s definitely a lovely thought but its not quite true, is it?
At least to this Electrical Engineer, who has over the past 20 years earned a ‘vocational degree’ in Computer Science, it is clear to me that until some sort of foundational concepts akin to Matter and Energy are established for CS, it will never attain to the same rigor that underpins physically rooted sciences (such as Physics, and its applications, e.g., engineering).
(I was happy to note recently that a CS luminary such as Lamport pretty much articulated the same thing.(
May 10th, 2009 at 2:24 pm
And here is another case of the comment being just as interesting (if not more interesting) than the article itself! I agree with almost everything Ben Hyde has said, and am proud to be a computer scientist for those exact reasons!
May 10th, 2009 at 2:36 pm
Plus, er, Scheme never really worked. I mean, yeah, it ran, but it was always hopelessly, inexcusably slow and demanding. It’s STILL demanding; it errors out on my Ubuntu box, while all the widely used languages run fine. Once, for a course, I wrote a g-machine interpreter in scheme. But scheme was so hopelessly slow I did 95% of the testing in emacs-lisp. I’m glad MIT’s finally come to their senses and moved to something that, er, works. The new approach sounds promising, too, since that was my first programming job, and it worked for me.
May 10th, 2009 at 4:46 pm
Relevant bits here; interpret as you wish (it certainly wasn’t because of the language):
http://www.wisdomandwonder.com/link/2110/why-mit-switched-from-scheme-to-python
May 10th, 2009 at 11:16 pm
With all due respect, the fact that systems are buggy and complicated (not just complex) is due to generations that have NOT had access to SICP. It seems to me the prudent reaction would have been to add a “dealing with complex systems” module to the curriculum, instead of depriving it of the masterpiece that teaches them to do better.
May 10th, 2009 at 11:55 pm
Hmm. First, I think computer science and electrical engineering ARE different disciplines. 30 years after taking 6.003, I have yet to use a z-transform for anything, period. Sure, there are situations in which you need to know both disciplines, but that doesn’t mean they’re the same thing. In retrospect, I would have been much better served if the algorithms course had been required instead — I didn’t take it, and realized only after graduating how valuable it would have been. (The 6.002 material was of more general interest; I wouldn’t replace that course, though I personally haven’t used that much of it.)
I don’t care that much about the change from Scheme to Python. But this bugs me:
“In 1980, computer engineering was based on starting with clearly-defined things (primitives or small programs) and using them to build larger things that ended up being clearly-defined. Composition of these fragments was the name of the game.”
It’s still very much the name of the game if you’re doing systems programming: operating systems, compilers, libraries. I suppose this kind of programming is a smaller fraction of the entire scope of software development activity these days, but it is by no means dead — and if you can’t do it, I certainly don’t want you in my group.
That said, I think the students with an aptitude for the mathematics of programming will find a way to pick it up, if given a modicum of encouragement. I hope there is still an SICP class, even if it’s not required.
May 11th, 2009 at 1:58 am
This is silly. Are you producing scientists or engineers? If former, there is no better introduction to the world of CS than LISP. If later, why not just teach them how to copy and paste Java code? Because that’s what 90% of software developers do these days…
May 11th, 2009 at 2:39 am
[...] A recent post about the death of 6.001 caught my attention earlier today, and I’ve been stuck composing this blog post in my head for awhile. [...]
May 11th, 2009 at 6:54 am
[...] just read that MIT software engineering curriculum switches from Scheme to Python. The story raises an interesting point – the curriculum changed since they realized that as the [...]
May 11th, 2009 at 8:25 am
It is true that few real-world engineering programmers meet an experience like 6.001. How much more important, then, that they have this view of the stars before industry clouds their eyes. For many, that one brief view of the Heavens has inspired a career.
May 11th, 2009 at 9:01 am
I took 6.001 in the Spring 1982 and it was taught using SCIP. So your statement “The freshman software engineering course, since 1985, has been based on the book Structure and Interpretation of Computer Programs (known as SICP), which uses Scheme” is misleading at best.
May 11th, 2009 at 2:53 pm
B. Factor: I got the 1985 date from Wikipedia. The official SICP site http://mitpress.mit.edu/sicp/ says that the copyright date is 1984. Perhaps you were using a “course notes” or preprint version?
May 20th, 2009 at 4:17 pm
He was. I was a TA for 6.001 in spring and fall 1982 and SICP was a big binder of looseleaf pages.
May 24th, 2009 at 1:53 pm
[...] Dan Weinberg in his comment below, Sussman endorses the changes in the new curriculum, though. His post on this issue is worth reading too. Posted in History, Lisp, Scheme. 6 Comments [...]
May 31st, 2009 at 3:31 pm
[...] Weinreb: “Why did M.I.T. Switch from Scheme to Python?” “Nowadays, a real engineer is given a big software library, with a 300-page manual that’s full of errors. He’s also given a robot, whose exact behavior is extremely hard to characterize (what happens when a wheel slips?). The engineer must learn to perform scientific experiments to find out how the software and hardware actually work, at least enough to accomplish the job at hand. Gerry pointed out that we may not like it this way (”because we’re old fogies”), but that’s the way it is, and M.I.T. has to take that into account.” [...]
June 1st, 2009 at 9:19 am
It’s rather sad that so many of the responses I’ve seen to this elsewhere (LtU, etc) have continued to focus on the language change and ignored the core point that you made, here. I suppose the other way to look at this is: do you really think that the language of choice will impact the quality of eduction?
I could see a point being made, here, that if the language of choice were C, then there are too many constructs that would require too long to develop and thus the course would have to miss out on some material, but once you’re talking about a high level language with a minimum of functional and ease-of-use features, the real question is: what is being taught? So that brings us to the truly interesting question: is this one of the courses that MIT will be publishing online?
Currently , the old course is up:
http://ocw.mit.edu/OcwWeb/Electrical-Engineering-and-Computer-Science/6-001Spring-2005/CourseHome/index.htm
June 4th, 2009 at 7:36 pm
Really great post – I’ve been looking for info like this for awhile.
June 7th, 2009 at 9:05 am
[...] names for the articles, in order to attract readers. Sometimes it backfires. In my case, I used “Why Did M.I.T. Switch from Scheme to Python?” for an entry whose point was that the switch is not what’s important. But perhaps since it [...]
June 9th, 2009 at 11:56 am
You can understanding programming to transform data or you can understand programming to control physical devices. MIT seems to have switched from one to the other. Both existed 30 years ago and both exist now. Unfortunately, the revival of functional programming seems to see MIT going the opposite direction. Are we heading into a world where we are surrounded by robots? Or, are we going to build upon our growing mathematical understanding of the world (quantum physics, chemistry, symmetry, chaos, new electronic devices, and pure programming like category theory)? Or, both? I think a focus on controlling physical devices is a narrow range of computing applications. I am concerned that way too many programmers already know nothing about functional programming. I would hate to see that grow worse.
June 10th, 2009 at 3:49 pm
You made some good points there. I did a search on the topic and found most people will agree with your blog.
June 12th, 2009 at 6:34 am
@Ezekeil: Don’t forget that this is only the freshman curriculum. They have another three years to learn a lot more about computer science.
I’ve been reading “Real World Haskell” and I agree that understanding functional programming is somewhere between fascinating and essential knowledge (thanks to my friend Alan Bawden for making it clear to me how valuable it is to learn this). The book is really great and I hope to find time to finish it.
July 17th, 2009 at 10:15 am
[...] Why Did M.I.T. Switch from Scheme to Python? [...]
August 16th, 2009 at 3:12 am
[...] to use for CS1 is heating up again. This round seems to be about moving from Java to Python. MIT’s switch from scheme to python last year is getting [...]
September 30th, 2009 at 5:36 pm
[...] Dan Weinreb’s blog » Blog Archive » Why Did M.I.T. Switch from Scheme to Python? Why Did M.I.T. Switch from Scheme to Python? (tags: python programming development mit) [...]
February 2nd, 2010 at 8:06 am
Is phyton harder to learn than scheme?