Map coloring algorythm