« Return to Thread: Io N00B - basic questions

Re: Io N00B - basic questions

by Steve Dekorte :: Rate this Message:

Reply to Author | View in Thread


On 2009-04-21, at 2:21 PM, Samuel A. Falvo II wrote:

> On Tue, Apr 21, 2009 at 2:14 PM, Friedrich Weber
> <fred.reichbier@...> wrote:
>> myObject setA(123) setB(456) setC(789)
>
> myObject do(
>  a = 123
>  b = 456
>  c = 789
> )
>
> is shorter still.  ;)

In characters, the set style is 38 and the = style is 41.

BTW, it's considered good style in Io to always use setters outside of  
an object, and to use them preferentially within an object.

 « Return to Thread: Io N00B - basic questions