I have a table right here {"String 1", "String 2", "String 3", "String 4", "String 5"}
I want to select element 3 to 5...
1 | local number = 0 |
2 | for _, string in pairs (yourtable) do |
3 | number = number + 1 |
4 | if number > = 3 and number < = 5 then |
5 | --is under 3/5 or equal to 3/5 |
6 | end |
7 | end |
or
1 | local number = 0 |
2 | for _, string in pairs (yourtable) do |
3 | number = number + 1 |
4 | if number = = 3 and number = = 5 then |
5 | --is under 3 or 5 |
6 | end |
7 | end |