The overall winner is the cyclist who completes all race days in the shortest amount of time. This is the general classification competition and during the race the leader (cyclist with the shortest time overall after each stage) wears the yellow jersey.
However, there are three other competitions.
Green jersey
Polka dot jersey
White jersey
Green jersey is for the most points for sprinting. Along each stage there are sprint checkpoints where points can be won. Also at the end of each stage on the flatter stages you will see the sprinters compete to win at the end of the race for points. The cyclist with the most points at each stage for sprinting gets the green jersey.
Polka dot jersey. This is for kimg of the mountains. Some stages go through the alps and/or the Pyrenees. Again points are earned at various checkpoints. The cyclist with the most mountain stage points at eac stage wears the polka dot jersey.
White jersey. This is the best young rider competition and I think it's a combination of points and quickest time. The only qualification to be a young rider is you must be under the age of 25.
Hope this helps.