- To: slug@xxxxxxxxxxx
- Subject: Re: [SLUG] Your top-ten linux desktop apps
- From: Bruce Badger <bwbadger@xxxxxxxxx>
- Date: Thu, 29 Sep 2005 18:52:29 +1000
- Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=nBPJ/kgB44rcH/0YpCq2NAuD9TkyiUbK4ZGtbhgjQ7hvuVNyMIlKS2yug0T1c8xQ0wGzG66WDJKdn6nTQyN7K+EU1qms2nq97gLUTSaslKOgIXvw320+T4mvpHu2aBpHObqKJp08S/sbzBV1/3/5z4fpgA3+66o63oJ81l1QHs0=
- Reply-to: Bruce Badger <bwbadger@xxxxxxxxx>
On 9/29/05, Andrew Bennetts <andrew-slug@xxxxxxxxxxxx> wrote:
> Python can be nicer than that:
>
> integer_array = [1, -2, 3, -4, 5, -6, -7, 8, -9, 32727000]
>
> for index, value in enumerate(integer_array):
> print "integer [%d] = %d" % (index, value)
So can Smalltalk! :-)
integerArray := #(1 -2 3 -4 5 -6 -7 8 -9 32727000 9876543210).
integerArray doWithIndex: [:element :index|
Transcript show: 'integer [', index printString, '] = ', element
printString; cr]
(can you other guys handle the big number I added at the end OK?)
Of course, beauty is in the eye of the beholder.
All the best,
Bruce
--
Make the most of your skills - with OpenSkills
http://www.openskills.org/