If i have a variable $num = 50
how can i put numbers 1-50 into an array?
(50 is an example.. i wont know how many questions)
views:
319answers:
3Example is broken. , instead of ..
erenon
2009-11-21 12:33:10
Example was broken but function is the right one to use. No need to give negative feedback - the answer is still useful.
ChronoFish
2009-11-21 13:02:42
`..` is the perl range operator: `my @range = (1 .. 50); my @alpha = ('a' .. 'z'); `
Rob
2009-11-21 13:04:17
@Rob, also the Python range operator.
Alix Axel
2009-11-21 13:49:44
eyze: and the pascal as well...
erenon
2009-11-21 13:50:24
Sorry! Been writing too much haskell. Thanks for the edit.
Matt Ellen
2009-11-22 12:49:11