Step 1: Understand what is being asked.
The cube has 8 corners: a, b, c, d, e, f, g, h. We need to color every corner so that any two corners joined by an edge get different colors. We want the smallest number of colors that makes this possible.
Step 2: Split the corners into two groups.
Look at the cube as two squares, the top face and the bottom face, joined by four vertical edges.
Put a, d, f, h in Group 1 and b, c, e, g in Group 2 (this is the usual alternate-corner split of a cube, where every edge joins a corner from Group 1 to a corner from Group 2, never two corners from the same group).
Check a few edges: a-b, a-c, a-e all join a Group 1 corner to a Group 2 corner, and this pattern holds for every edge of the cube.
Step 3: Color each group with one color.
Give every corner in Group 1 color X and every corner in Group 2 color Y. Since every edge always connects one corner from Group 1 to one from Group 2, no edge ever joins two corners of the same color.
So 2 colors are enough to color the whole cube correctly.
Step 4: Confirm that 1 color is not enough.
Any two corners joined by an edge cannot share a color, so we need at least 2 colors. Using only 1 color would force every edge to join two same-colored corners, which breaks the rule. Options (A) 8 and (B) 4 use far more colors than needed, and (C) 3 is also more than the minimum, since the whole cube splits cleanly into just two groups.
Final Answer:
The minimum number of colors required is 2, which is option (D).
\[ \boxed{2} \]