i have a string variable which contains comma and dash separated data
str="2,4-8,11,15-22,39"
i want to convert it to array of continous values
like
newstr(1)=2
newstr(2)=4
newstr(3)=5
newstr(4)=6
newstr(5)=7
newstr(6)=8
newstr(7)=11
newstr(8)=15
newstr(9)=16
newstr(10)=17
newstr(11)=18
newstr(12)=19
.
.
.
newstr(15)=22
newstr(16)=39
etc
how can i do this
...
Go to the complete details ...