2 ms·
No, this is not a typical line of Smalltalk. That would be considered a very sloppy array indeed. I think it's just there to demonstrate the different literal n
by scroot 6y ago
No, this is not a typical line of Smalltalk. That would be considered a very sloppy array indeed. I think it's just there to demonstrate the different literal notations in the language.
Smalltalk is actually quite readable in practice, though the keyword syntax seems to throw off experienced programmers from other languages. It's worth noting that the language was originally tested on children, so it was also designed to be easy to read and learn.
The equivalent of your C code above could be something like:
MyObject doSomethingWith: anArgument
- PaulDavisThe1st 6y agoaka Objective C :)))