Re: [Pharo-dev] new pharo cheatsheet
On Apr 9, 2016 8:11 AM, "Ben Coman" <btc@openinworld.com> wrote:
On Sat, Apr 9, 2016 at 6:16 AM, Damien Pollet <damien.pollet@gmail.com>
wrote:
On 8 April 2016 at 22:57, Sven Van Caekenberghe <sven@stfx.eu> wrote:
Since we are simpler and more logical, a cheat sheet should not confuse people by describing what we are not.
I beg to disagree. "Simpler and more logical" is just your biased point of view; fact is, zero-based indexing is just more widespread in programming languages.
I would be happy to be proven wrong about that, but I seriously doubt most people that come to Smalltalk have never been exposed to programming before. It's not unreasonable to assume that they've started programming in any one of the most popular languages these days, and that that language is zero-indexed. So mentioning that in Smalltalk the first element is indeed at index 1 is pretty essential, if just to lift the ambiguity.
+1. But to follow Sven's point exactly. We don't need to say we are "not 0 based", just that we are "1 based".
And we do not need to know most of the time since we have a pretty decent collection API. Or for matrixes for that matter. Phil
cheers -ben
participants (1)
-
philippe.back@highoctane.be