I have a list and I have to find consecutive sequences in that list.
For example if my list is [1,2,3,5,7,8,9]
then code should return [1,2,3]
and [7,8,9]
And if the list is [3,5,6,7,8,10]
it should return [5,6,7,8]
Please suggest me something how I can code it to find the consecutive sub-sequences?