Finished implementing of the first coloring algorithm