Like terms" are terms whose variables (and their exponents such as the 2 in x2) are the same.
In other words, terms that are "like" each other. Since, exponential power of 7x and 7xy are not same. Therefore, they are not like terms.
Why constants like gravitational constant are not dimensionless but constants like 2,3 are dimensionless