TCLUG Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

create a list of numbers



I want to create a list of numbers for a "for" loop: ie
for i in 1 2 3 4 5 6 7 8
....

but i do not want to type from 1 to (anything actually)
and i was wondering if there was a way to give a range that
would be expanded and could be used in a for loop.

(i know i could use a while loop, but i'm curious now, and am interested
 for a learning experience )
for i in (some expression that expands to 1 - 10)
do a bunch of neat stuff

any ideas ?