coloring visited edges