Line Following
Line following is something that allows a robot do a task involving lines and/or positioning with lines. There are many ways to do it, but the programming is divided into two categories: State Line Following and Proportional Line Following.
One way to line follow is to use a dual/triple state line following algorithm. The robot's motions are very jerky, but it will never go off course. Note how the programming is very simple.
The second way, and more accurate and smoother way, is called proportional line following. The robot will turn an amount proportional to the value of the error, or how much the robot is off track. The programming is way more complex, but the benefit is that there will be less time involved in line following.