A={x:(x−1)(x2−10+21)=0}
(x−1)(x2−10+21)=0
⇒(x−1)(x2−7x−3x+21)=0
⇒(x−1)(x−7)(x−3)=0
⇒x=1,3,7
B={y:y is a prime factor of 42}
Prime factors of 42 is 2,3,7
Common elements between A and B is 2.
∴ The number of common elements between A×B and B×A is 22=4