For sitting group $Y$ together:
Seat one of the people in group $Y$ arbitrarily. We count this as being do-able in $1$ way because of the symmetry of the circle.
Seat the other group $Y$ person ($2$ ways).
Seat the remaining $4$ people (group $X$) ($4!=24$ ways).
Total: $48$ seatings possible.
For sitting group $Y$ apart:
Seat one of the group $Y$ people ($1$ way (as above)).
Seat the other group $Y$ person ($3$ ways--to keep that person away from the other $Y$ person).
Seat the $4$ from group $X$ ($24$ ways).
Total: $72$ seatings possible.