C# Programming
06-22-2009, 08:02 AM
Hi,
I have numbers 1 to n(let it be 1 to 10).. They are in sequence and in ascending order but some of the numbers in between are missing. For example(1 2 3 5 6 9 10).
I need arrays from the numbers those are in sequence.
Like:
Array1: [1,2,3]
Array2: [5,6]
Array3: [9,10]
Note: It is also needed to calculate how many arrays we can get?
Can some body please help.
I have numbers 1 to n(let it be 1 to 10).. They are in sequence and in ascending order but some of the numbers in between are missing. For example(1 2 3 5 6 9 10).
I need arrays from the numbers those are in sequence.
Like:
Array1: [1,2,3]
Array2: [5,6]
Array3: [9,10]
Note: It is also needed to calculate how many arrays we can get?
Can some body please help.