Since it asks for the degree of the function, that means we must look for the variable with the highest degree. In this case, after distributing and simplifying out the last equation, we will find that the variable x has the highest degree of x^6, or 6.