
26 Mar
2018
26 Mar
'18
1:52 p.m.
Hello, I try to achieve this but I can not find a convenient (elegant solution) let l =[1,2, 3, 4, 6, 7, 9, 10] I want this [[1, 2, 3, 4][6, 7],[9, 10]] In fact I want to split a list with all consecutive series. I imagine that it existe a one-liner for this but I did not find it :)) Cheers and thanks for your help Frederic