S is to the immediate right of P and to the immediate left of Y i.e.P,S,Y. X is on the immediate right of Z i.e.Z, X. Q and Y have two children between them i.e. Q, P, S, Y. X and P have one child between them i.e. Z,X,Q,P,S,Y. Since P and R have two children between them, the arrangement from left to right in the line becomes: Z,X,Q,P,S,Y,R. So R is on the extreme right.