Hacker News new | ask | show | jobs
by vince_refiti 4137 days ago
This is the kind of thing sorely missing from other language teaching - once you learn the basics, how to write good, idiomatic code? Btw, I can also recommend Kent Beck's Smalltalk Best Practice Patterns is you are learning Pharo Smalltalk.
2 comments

Thanks for the reference, I just ordered a copy. I have been using Pharo lately and I need a brush up on good coding practices.

The linked article is good and surprised me, especially using 'define' inside functions instead of 'let'.

A pre-publication version http://stephane.ducasse.free.fr/FreeBooks/BestSmalltalkPract... is in Stéphane Ducasse's free collection of old Smalltak books http://stephane.ducasse.free.fr/FreeBooks/ , though not linked from that page for some reason.
This has also surprised me. And it seems the main reason is that of indentation. I do not feel this is enough reason to use 'define' instead of 'let'.
> once you learn the basics, how to write good, idiomatic code?

... apart from reading good source written by others, which you can't really find by yourself since you lack the "good taste" needed to judge the quality of a piece of code. I'd be interested in a compilation of good snippets of source code for several languages. For example (I may be wrong) like PAIP for Common Lisp.