[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [sc-users] incrementing C-style



sure - i've been doing c = c+1;.  it's not standing in my way or anything.  i guess i just like the compact ++ and += operators.

not that important...just wondering :)




On Dec 21, 2007 3:08 PM, Julian Rohrhuber <rohrhuber@xxxxxxxxxxxxxx> wrote:
>hello,
>
>just wondering if there's some simple syntax for incrementing
>counter-type variables.  maybe something similar to the C "i++" or
>"i += 1" expressions?  i tried googling sc-users for a thread on
>this, but came up with nothing.
>

maybe:

c = {:x, x<-(0..) };
c.value;
c.value;

well..

or:
c = [0];
c.atInc(0);
c.atInc(0);

but why not:
c = c + 1; ?

--





.
_______________________________________________
sc-users mailing list
sc-users@xxxxxxxxxxxxxxx
http://www.create.ucsb.edu/mailman/listinfo/sc-users



--
William Brent

"Great minds flock together"
Conflations: conversational idiom for the 21st century

www.conflations.com