Graph Theory

Answer & solution
Answer: D (no official key was published)
Step 1: Separate even and odd cycle lengths.
Step 2: Label successive vertices alternately red and blue. When n is even the last vertex is blue and the first red, so the closing edge is legal. When n is odd both would be red; recolor the last vertex with a third color. The expression n−2floor(n/2) is exactly zero or one, so the option captures both cases rather than claiming one constant color count.
Conclusion: An even cycle alternates two colors. An odd cycle cannot alternate consistently around the closing edge and needs a third color, which suffices. Thus χ=2+(n mod2)=n−2floor(n/2)+2, D, for an ordinary cycle n≥3.