Given:
n(A)=3 and n(B)=2; and (x,1),(y,2),(z,1) are in A×B.
Apply cartesian product of two sets
As we know,
A= Set of first elements of the ordered pair elements of A×B
B= set of second elements of the ordered pair elements of A×B
So, it is clear that set A= {x,y,z} and set B= {1,2}.