Live data from Hacker News

Retiring Python as a Teaching Language

prog21.dadgum.com

141–150 of 238 posts

Re: Retiring Python as a Teaching Language

#141
post #23

As much as i can't disagree with the choice (the realpolitik of programming has made it the most correct choice), i am saddened that the language on which the choice falls is one not chosen based on any merit, but merely due the historical accident of being the first to be implemented in a browser and having had no appreciable opposition due to browsers at the time being in hands of corporations. In "A Deepness on th…

I thought Java was the first to be implemented by the browser?

Java was introduced in Netscape Navigator 2 at the same time as JavaScript. But Java was really not integrated with the html at all. It lived in its own isolated box on the page. JavaScript was integrated with html and with the browser environment.

Re: Retiring Python as a Teaching Language

#142

I'm saddened by the lack of academic rigour displayed in this thread. If you have not taught introductory computer science courses, then you have NO CLUE what makes a good introductory language choice. It appears James Hague isn't working as a teacher either, just giving advice to newbies, so his opinion is just that -- opinion. What you want is field studies: "This year we used Haskell and 75% of all students gave u…

> What you want is field studies: "This year we used Haskell and 75% of all students gave up on programming stating that it was to hard. Last year we used Visual Basic and only 20% did. Ergo Visual Basic is probably a better first language than Haskell." Why is that necessarily a good thing? What are we optimizing for here, understanding or popularity? SICP review by Peter Norvig: > Donald Knuth says he wrote his boo…

I loved SICP when I worked through it, but I was already an experienced programmer at that time. I venture to guess that most of the people praising SICP actually has programming experience before reading it, even if the book purport to be an introductory course.

I would probably have given up on programming if SICP had actually been my introduction to programming.

Re: Retiring Python as a Teaching Language

#143

I think this author has lost his focus. Maybe there's only 1 choice if you want something to sit "on top", but anything can interact with "an unprecedentedly ubiquitous cross-platform toolkit for layout, typography, and rendering". Including Python. For games, an introductory class using Python with Kivy or PyGame doesn't fit the bill because they may not always be around? If a student really wants to go deeper into…

So much anger

Re: Retiring Python as a Teaching Language

#144

When I took an introduction to Computer Science in college, it was taught in Racket. Over winter break, I then learned Python, and I was baffled -- why would any curriculum not start with Python? Python was easy, expressive, and allowed the user to get lots done with little effort. It was great at motivating programming by showing its use and power. It seemed like an ideal introductory language. Over the last few yea…

> Thus, I don't really think that learning Python offers solid programming foundations. I agree. But there is a huge class of people that this argument tends to miss - all the people who learn programming as a tool and not a way of life, like scientists or engineers from other departments. For those, it's ideal to learn one language, and it's OK if they don't completely understand CS. For them it's better to know a l…

Yes, that's a good point. Some people might not actually need to cultivate a deep understanding of CS -- they just need a tool to get the job done. Not everyone who uses a hammer needs to take carpentry lessons. In that sense, Python can be a very appropriate choice.

Re: Retiring Python as a Teaching Language

#145
post #112

Earlier quoted context omitted.

It's important to ask "teach what?" There are a lot of foundations that simply aren't going to be relevant to large subsets of students. Teaching C, for instance, is nearly useless if you're trying to convey FP concepts or object-orientation. I certainly support including C as a core part of any university's Computer Science curriculum. But such a curriculum should include as many languages as possible, each delibera…

> Teaching C, for instance, is nearly useless if you're trying to convey FP concepts or object-orientation. C is superb for teaching how to manually implement polymorphic behavior in the absence of object-oriented features. Using it to demonstrate how (class-based) OO languages work should be standard in any course that has CS in its title. (Using it to demonstrate how to implement prototype-based inheritance would b…

> C is superb for teaching how to manually implement polymorphic behavior in the absence of object-oriented features.

Building a complex language from scratch is fine, but doing it by extending C isn't the best way.

I happen to like C. I'm good at C. I understand the C mindset, to the extent it has one, and it isn't especially conducive to OO. (It's absolutely horrible with FP, because the fact you have to manage memory manually does terrible things to function composition.) Which would be fine, if C were actually a low-level language. It isn't.

C gives you a simplified, high-level machine model. It isn't that close to the machine; if it were, you'd have access to things like SIMD hardware and everything else C can't give you because it would break portability.

(OK, you could possibly have access to them if you used C to implement an interpreter for a virtual machine. But that kind of defeats the purpose.)

So sure, implementing a non-trivial programming language is a fine goal; however, I'd do it by generating assembly language, because doing it in terms of C forces the programmer to adopt C's limitations (every function has a single return value because there's no real stack access; there's no access to processor flags; no access to parallelism of any kind; etc. etc. etc.) for no real benefit in that context. (School projects don't have to be portable.)

Edited to add: And if you're writing a compiler, C isn't especially interesting. Haskell and parser combinators are interesting; Common Lisp and macros are interesting; Python is, again, not especially interesting, but at least with Python you're debugging errors related to the problem domain, as opposed to errors related to the intricacies of manual memory management.

(Edited for comprehensibility as well.)

Re: Retiring Python as a Teaching Language

#146
I've been through the Udacity CS101 and progressed well with their programming languages and design of programs courses. These are all in Python but I have covered interpreters, compilers, regex, recursion, types, etc. These all treat python as a tool to learn CS not just the language in itself. Alongside these courses I've also been building my own websites using Django and I'm now at a stage where I feel I can solve any problem in any technology (even though it will take me longer than someone experienced in that technology to learn it and get stuff done).

I've started exploring other languages (C, Lisp, even Java at work, Haskell next, javascript) and feel much more confident with the software engineering stuff that CS courses don't necessarily cover, having managed development teams (git, deployment, CI, TDD, etc). I agree with other commenters that python gets out of the way so that you can explore CS concepts.

Javascript could be a good intro language but students might want to move onto something else fairly quickly. I already tried js first and quickly started CS courses because I didn't feel that learning javascript was helping me understand how to solve problems with programming. I also don't think you can teach all of the core CS concepts with javascript as effectively as you can with other languages (e.g. OOP), so when you do start teaching js they will still come to you and say "how do I put this on a website", "use node", "ok but how does that work? why does that work? etc, etc". And when it comes to websites are you going to teach students to build a webserver in vanilla js (?!) or reach for node that abstracts so much that is going on under the hood?

Smart students are always going to ask questions and I've found in my experience that I've been able to either get the answers or know where to get the answers, by knowing core CS concepts. So whatever language you choose to start off with it needs to be couched in terms of what CS it exposes.

Re: Retiring Python as a Teaching Language

#147
post #25

Earlier quoted context omitted.

What's pretty funny is that the new features in ES6 and ES7 makes a lot of the patterns/mishaps/X-parts from the last 15 years pretty irrelevant or less-obviously-'the way'. Examples: * "Class" syntax * Comprehensions * Modules * `let` scoping * Generators It's a whole new ball game. I think a lot (over 50%) of JavaScript devs 5 years from now will still be using <= ES5, but only because they've so settled in their w…

> I think a lot (over 50%) of JavaScript devs 5 years from now will still be using 5 years from now, there will still be people whose customers require IE6 support, too. We're still working on that.

The customer I am on, still uses IE 8!

Re: Retiring Python as a Teaching Language

#149

Earlier quoted context omitted.

While I disagree with the author that this is the penultimate goal that should be overriding all other concerns. I'll bite for the sake of discussion. If that's the goal then Javascript was obliterated before the OP woke up to write this ill-conceived blog. What people are building with Python on Kivy (chose the nearest example)- https://itunes.apple.com/us/app/deflectouch/id505729681?mt=8 Vs. What people are buildin…

Just because someone doesn't have a javascript heavy blog (which is designed to be mostly text) in no way means they think must think the whole web should be kept JS-light, or that JS isn't a worthwhile technology to build interactive applications with. They could believe in an appropriate use of technologies. There are plenty of technologies for getting JS based apps into app stores, just as there is for Python base…

Yeah, unfortunately the discussion was around getting people to program so they had something to show others. Not getting your application out there to as many people as possible. Sounds like a kneejerk defense of your chosen platform than honest contribution to me.

Not that you've proven this new point either. At $99 per student for impact.js just to learn on, I think the only thing undoubted is that you're desperately grasping for straws.

Paid software compared to Python's ecosystem that provides something better for free. Along with more varied libraries, and a better language too. Maybe as a teacher you could buy just one copy and pop the hood and show them that source code on how this is built.. oh wait, it's not open source. Also the slight snag that impact.js doesn't have support for Android. Which happens to be the largest mobile platform in the world. For only $99.99! You may as well have sent me Xamarin to compare with Kivy and tell me how C# was the way to go.

Use what you want to teach with. But using these harebrained reasons concocted as to why you'd want to push something like JS over a PL of Python's caliber make no sense at all.

Re: Retiring Python as a Teaching Language

#150

I completely disagree with the argument here. The class isn't a class to teach graphics or to teach how to make android games or how to put something on a phone. Beginning computer science classes explicitly should not be about those sorts of things. Beginning computer science classes should explicitly be about what a program is, what a function is, abstractions, and so on. Not "what does code look like". Not "how do…

Do note that the author is not a Professor teaching CS. If you click through the link in the first sentence of the post, this is the question he was trying to answer: "What's a good first programming language to teach my [son / daughter / other-person-with-no-programming-experience]?" His post wasn't really about teaching CS to students who are paying for years of classes. For his target audience, motivating them and…

Everything the GP said above is correct, though. Since so many people's first exposure to programming is through one of these languages, many people are simply unaware that it's possible to do better. Many people find it hard to switch from their first language. I agree with you that Haskell, Rust, and (to a much lesser extent) Lisp have the problem that it's hard to get started with easy graphical libraries aimed at beginners, though I don't agree that that's the case for Python. This is why historically there were languages like Logo explicitly designed as "Lisp for beginners," but today most such attempts seem to simplify programming to the point that it can hardly be described as programming at all (thinking of tools like Scratch).
Post reply on HN