While studying, I found a problem in my book that read: "Each vertex of convex pentagon ABCDE is to be colored with one of seven colors. Each end of every diagonal must have different colors. Find the number of different colorings possible."
The answer key showed the answer as 7770. The answer key also explained that you needed to find the number of ways to color the pentagon with 3, 4, and 5 colors, then add the numbers up. But other than this, no explanation was given. Could someone please give me an explanation to reaching this answer of 7770?