# Splitting curves Using de Casteljau's algorithm, we can also find all the points we need to split up a Bézier curve into two, smaller curves, which taken together form the original curve. When we construct de Casteljau's skeleton for some value `t`, the procedure gives us all the points we need to split a curve at that `t` value: one curve is defined by all the inside skeleton points found prior to our on-curve point, with the other curve being defined by all the inside skeleton points after our on-curve point.
### implementing curve splitting We can implement curve splitting by bolting some extra logging onto the de Casteljau function: ``` left=[] right=[] function drawCurve(points[], t): if(points.length==1): left.add(points[0]) right.add(points[0]) draw(points[0]) else: newpoints=array(points.size-1) for(i=0; i This is best illustrated with an animated graphic (click to play/pause):