TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Smalltalk vs. Scheme, JavaScript, and Java

43 pointsby horridoover 8 years ago

9 comments

Lordarminiusover 8 years ago
Another acerbic article from Richard Eng critiquing javascript.<p>Granted that javascript is inconsistent and poorly designed. But what does he expect a beginner programmer to do? Learn a language has neither widespread acceptance nor community support, in an attempt to get away from javascript&#x27;s deficiencies?<p>Even Google could not wean sophisticated programmers (who appreciate the issues way better than I and many others do) away from javascript despite its incredible efforts.<p>I for one am interested in getting the job done quickly and as painlessly as possible. I dont make the tools I just use them.<p>Thoughts anyone?
评论 #13003985 未加载
评论 #13028005 未加载
评论 #12998867 未加载
评论 #13000272 未加载
qwertyuiop924over 8 years ago
To the contrary, Scheme&#x27;s prefix notation reads quite well, particularly if you use indentation well. But that&#x27;s just my opinion.<p>Several of the statements in this article about Scheme are, however, objectively wrong.<p>-Scheme isn&#x27;t functional. It makes no effort to control side-effects, and a lot of Scheme is heavily stateful. In fact, the very Scheme example you wrote isn&#x27;t functional at all!<p>-Scheme isn&#x27;t uncomfortable for OO. Multiple OO frameworks have been written in Scheme (most of them based upon CLOS), and many of them are very comfortable and quite excellent. If you don&#x27;t like multiple-dispatch functions, it&#x27;s also possible to implement smalltalk-style object-message syntax (and indeed, people have done so).<p>In fact, if you look into the history of Scheme, it was orginally written by Sussman and Steele to help them understand the Actor Model, which is quite similar to OO: a program is modeled as many stateful actors, which can only communicate through messages.<p>Finally, the &quot;confusing&quot; Scheme code in this article is not very well written. If you split the definitions like so, it becomes much more readable (also, vector-map! is already defined in many schemes, so you don&#x27;t even have to evaluate the top part):<p><pre><code> (define (vector-map! f v) (do ((i 0 (+ i 1))) ((= i 0) v) (vector-set! v i (f (vector-ref v i))))) (define (make-matrix rows columns) (vector-map! (lambda (a) (make-vector columns)) (make-vector rows))) </code></pre> Again, there are several common extensions (in various SRFIs) that would make this even cleaner. In the upcoming R7RS-large (the Red standard, which has these functions, has just been released), I would merely need to import one library, and vector-map! would be defined for me, as is already true in many implementations.
评论 #12999672 未加载
评论 #13000069 未加载
评论 #12999739 未加载
throwaway7645over 8 years ago
Interesting how he critiques something cryptic in Scheme and doesn&#x27;t show the Smalltalk equivalent. One thing that should have its own full section is performance as it is slower than Java, compiled Scheme, and I&#x27;m guessing V8 optimized JS. I know the whole hotspot JIT thing was maybe pioneered in Smalltalk though? I do like certain things about Smalltalk (Pharo looks nice), but it is hard to do certain things with it like a GUI. Well I mean it is hard to find out how to do that....not necessarily hard to implement.
评论 #13005003 未加载
评论 #12999546 未加载
zengidover 8 years ago
&gt;&gt;[Smalltalk is] the perfect instructional language for teaching programming to both children and adults alike. It’s very easy to learn and extremely versatile...<p>Where&#x27;s the data to support this? Has anyone done a randomized double-blind study on new programming students using smalltalk vs groups using Scheme, JS, or Java? Why is someones biased opinion enough to justify this claim? We need to hold ourselves to a higher standard than to accept unsupported arguments (meaning they havent been tested empirically) [1].<p>[1] <a href="https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=uEFrE6cgVNY" rel="nofollow">https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=uEFrE6cgVNY</a>
评论 #12999763 未加载
评论 #13000036 未加载
webwanderingsover 8 years ago
Since it is addressing beginning programmers, I would like to add my take. I&#x27;m not a programmer but I have many years worth of computer experience. Programming never appealed to me because it never came naturally.<p>Lately I (once again) started paying attention to programming and started looking around. I went from one e-book and MOOC to another with much of the python hype (previously in my - failed - attempt, I tried Perl, PhP etc, when they were in vogue). Well I have eventually concluded, that the problem with programming is not necessarily me, but it is the lack of proper padagogy itself. There are programmers galore out there trying to teach via YouTube and MOOCs, but most are code monkeys who know what they&#x27;re doing but I wouldn&#x27;t call them &quot;teachers&quot;.<p>So my search eventually led me to Scheme&#x2F;Racket where I see some signs and hope of proper learning (I&#x27;m not going to be able to afford myself to take a college level CS). I looked into Small Talk as well but as of now I don&#x27;t see a proper MOOC on it. I have started Racket course (BSL) on EdX. After spending much time and energy chasing Python basics and going nowhere, i feel I can possibly and eventually learn programming the way it is meant to be.
评论 #13004903 未加载
dgreenspover 8 years ago
I see mostly criticisms unrelated to SmallTalk.<p>Scheme: Show me the code comparison. How is FP vs OOP relevant, even if true?<p>JavaScript: How is the comparison to Lisp relevant, especially after the preceding? Author just chose some appealing praise of JavaScript to tear down.<p>Java: This reduces to an argument you should consider SmallTalk at all for systems programming.
allengeorgeover 8 years ago
I found the critique unconvincing, especially since I don&#x27;t see any Smalltalk examples in the article to support his position. Not I that I doubt there are languages better than both JavaScript and Java.
throwaway7645over 8 years ago
I think a lot of his points still stand though with ST being elegant in a lot of ways and relatively easy to learn.
sebringjover 8 years ago
Please don&#x27;t format code with ))))))) at the end for the love of code! Use readable indentation instead as your whole point is to make things look simple to understand. That actually warrants a slap the back of your head from a team of onlookers, one at a time.
评论 #12999108 未加载
评论 #12999224 未加载
评论 #12998994 未加载
评论 #12999074 未加载
评论 #13001246 未加载
评论 #13000059 未加载
评论 #13000363 未加载