You are right. In statment 2 we can not have untill x and y are zero. But that mean median is 0 for set S and T. So B is sufficient. So how you get answer C.
Mean median of both sets will be the same only when it is 0. Stmt 2 is not sufficient as for other values also, stmt2 satisfies. For example, if mean median of S is 7 and of T is 5 then
for S, 5+6+7+8+9 = 35 and for T, 2+3+4+5+6+7+8=35.