Trey and Miles are correct — we can either use the reasoning “we do not
want for the two letters to be the same, so for the first letter we have 26
choices and for the second we have 25”, so we get 26-25, or we can find
the number of all two-letter codes, which we have 26-26, and subtract the
number of two-letter codes with a repeated letter, which we have 26.
Adding 26 and 25 makes no sense, since for each choice of the first letter we
have 2% additional codes.