I have an array suppose "ar" which has a number of elements.I want to travers or process the array elements according to a integer variable suppose "a" which can have 0 or 1 or 2 or 3 or 4 or or 5 or 6 and so on.....
Suppose ar has elements 1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31...
What i want when a=0 then the loop process the element 1 of ar
If a=1 thn process the elements 2,3 of ar
If a=2 thn process the elements 4,5,6,7 of ar
if a=3 thn process the elements 8,9,10,11,12,13,14,15 of ar
If a=4 thn process the elements 16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31 of ar
and so on......
Please if any one can do this i m thankful to him
thanks a lot in advance.........
Please everyone code project is a community with the greatest minds i need to solve this problem urgently please help..........