This network demonstrates how the Sweep SOP can be used to construct geometry that is easily deformable. The Sweep SOP requires a backbone and cross section geometry.
Through a sin() function an expression is created to animate the backbone for a slithering effect. Then the circles are copied at every point on the backbone to create the skeleton of the worm. Finally, a simple skin operation completes the worm body.