Fill the 1st square any of the 10 ways. That's 10 ways to color the 1st square. For every one of those 10 ways to color the 1st square, there are 9 ways to color the 2nd square, that is, with any of the 9 colors different from the color in the 1st square. That's 10*9 ways to color the first 2 squares. For every one of those 10*9 ways to color the 1st 2 squares, there are 9 ways to color the 3rd square, that is, with any of the 9 colors different from the color in the 2nd square. That's 10*9*9 ways to color the first 3 squares. For every one of those 10*9*9 ways to color the 1st 3 squares, there are 9 ways to color the 4th square, that is, with any of the 9 colors different from the color in the 3rd square. That's 10*9*9*9 ways to color the first 4 squares. For every one of those 10*9*9*9 ways to color the 1st 4 squares, there are 9 ways to color the 5th square, that is, with any of the 9 colors different from the color in the 4th square. That's 10*9*9*9*9 ways to color the first 5 squares. For every one of those 10*9*9*9*9 ways to color the 1st 5 squares, there are 9 ways to color the 6th square, that is, with any of the 9 colors different from the color in the 5th square. That's 10*9*9*9*9*9 ways to color the first 6 squares. That's all the squares, so the answer is 10*95 = 590490 ways. Edwin