In F # What is the best way to convert a finite sequence similar to seq [0; 1; 2; 3; 4] seq [0; 1; 2; 3; 4] seq [0; 1; 2; 3; 4] , in a sequence of tuples of the type seq [4,0,1 ; 0,1,2 ; 1,2,3 ; 2,3,4 ; 3,4,0] seq [4,0,1 ; 0,1,2 ; 1,2,3 ; 2,3,4 ; 3,4,0] seq [4,0,1 ; 0,1,2 ; 1,2,3 ; 2,3,4 ; 3,4,0] ?
Addition: My Seq is a cyclic data. In this case, the vertices of a closed polyline. I need neighboring elements to calculate the angle of each angle.
source share