Constructing a complete graph of degree N

A complete graph of degree N consists of line segments that connect all possible pairs of a given set of N points. The construction implemented here connects all possible pairs of vertices of a regular N-gon. The value of N='vertices' is selected with a slider. The two points connected are indicated by the sliders 'first' and 'skip'.

Determine the number of line segments when the number of vertices is 6.