I'd say Python would've been the 'safe' and 'sane' choice, but maybe it's just my bias against Java and JavaScript talking. Just curious, has anyone ever heard off choosing to teach something like bash / PowerShell? It might seem less intimidating than downloading a lot of stuff and students can play around with stuff already in their computer. Hell, maybe even something like VBA (as much we might dislike it) since n…
Stanford dumps java as intro language
41–50 of 50 posts
Re: Stanford dumps java as intro language
#42Earlier quoted context omitted.
Thanks for the insight. With your experience, what would be a good language for non-majors so that they can make use of their experience later? Python, Go, C?
I would definitely say Haskell. Second is python, but i feel Haskell teaches concepts better and more efficiently. Everybody has used spreadsheets before, and I think most people can draw a m mental link to spreadsheets with Haskell.
Javascript in the browser suffers at that because it's opinionated towards web, but OP sees that as a plus and web programming certainly is an applicable skill with a future. Not everyone would have to use facebook as homepage, for example
Re: Stanford dumps java as intro language
#43Earlier quoted context omitted.
Disagree, I think it is the exact opposite. I say that as someone who did their CS education in the early 90s when that was the case. We used C for everything unless the class material implied something else. We got into the down and dirty details quite fast. IMO that's the wrong way to do it. Using myself as an example it took me far longer to learn things like data structures than it should have. Why? Because I sti…
> IMO that's the wrong way to do it. Using myself as an example it took me far longer to learn things like data structures than it should have. Why? Because I still hadn't wrapped my head around pointers. How do you expect to understand anything about data structures if you fail to wrap your head around one of the most basic data structure mechanism around: referencing a memory address? In fact, how exactly do you ex…
If anything learning things this way would likely make learning about memory references easier?
Re: Stanford dumps java as intro language
#44Earlier quoted context omitted.
I keep hearing that people have (or had) trouble understanding pointers. As someone who has never had that problem or met such a person, I am struggling to understand why...
It's not so much as trouble with pointers as trouble with visualizing algorithms and data structures. Try implementing some moderately complex one in C. It reads like a monster. A dynamic language like Python would have a simpler implementation but at the cost of performance (Why do beginners need performance).
Re: Stanford dumps java as intro language
#45I'd say Python would've been the 'safe' and 'sane' choice, but maybe it's just my bias against Java and JavaScript talking. Just curious, has anyone ever heard off choosing to teach something like bash / PowerShell? It might seem less intimidating than downloading a lot of stuff and students can play around with stuff already in their computer. Hell, maybe even something like VBA (as much we might dislike it) since n…
Re: Stanford dumps java as intro language
#46Students who start by learning Java will learn solid principals which may be applied to Javascript (or any other language). Students who start by learning Javascript won't learn solid principals.
"Principles" not "principals". Everything depends how the course is taught, not on the language used.
Usually this statements holds true, but not in this case. I mean, after all we are talking about language where `'0' == false` is `true`.
Re: Stanford dumps java as intro language
#47Re: Stanford dumps java as intro language
#48Earlier quoted context omitted.
"Principles" not "principals". Everything depends how the course is taught, not on the language used.
> Everything depends how the course is taught, not on the language used. Usually this statements holds true, but not in this case. I mean, after all we are talking about language where `'0' == false` is `true`.
Once students know that JS has type coercion, and how to avoid this entire class of problems, they never need to know or think about what "0" == false evaluates to.
Re: Stanford dumps java as intro language
#49Earlier quoted context omitted.
I would definitely say Haskell. Second is python, but i feel Haskell teaches concepts better and more efficiently. Everybody has used spreadsheets before, and I think most people can draw a m mental link to spreadsheets with Haskell.
That's completely out of the question at the moment. True, it could potentially be most useful to know haskell for a lot of programmers, but at the moment, the opportunities to use haskell in the work place are actually rare and not to a small part because an understanding of haskell is barely achievable in an introductory semester, while the steep learning-curve of the language is kind of intended as it's usefulness…
The point of an introductory programming class is not to teach a language for vocational purposes, but to teach the basics of computation. Someone who understands computation can reasonably be expected to pick up most languages.
Re: Stanford dumps java as intro language
#50Earlier quoted context omitted.
JS is the new lingua franca, what C used to be. And unlike C it is easy to get started programming in it. Thus a good choice for an intro language if you ask me.
Learning to program is hard enough without having to worry about hoisting, truthiness, function vs block scope, prototypes, the many rules of this, "classes" that don't behave like classes, and other quirks unique to JS. Do you need to know all of the corner cases in order to write a simple script? No. But good luck trying to get someone to debug a JS program without a solid foundation. JS is a pedagogical disaster.
Prototype based inheritance vs class based inheritance will confuse exactly zero new people, since they will have zero prior experience with class based inheritance. Heck, if the goal is to teach algorithmic thinking and imperative programming (Stanford classes are 10 weeks long) then different forms of OOP don't matter at all.
Hoisting is weird, but is one of those things that can be worked around by teaching proper patterns and is no more mysterious to new people than whitespace errors in python or the magic word "static" in java or operator overloading in C++ or nightmarish type error messages in haskell.