(a) P shifts the ray more than R, twice as much. Same glass and same angle of incidence means the same angle of refraction, so the ray inside follows the same tilted path; in a slab twice as thick it travels twice as far along that path before emerging, so the sideways shift doubles.
(b) Q shifts the ray more than R. Same thickness, but the higher refractive index bends the ray further from its original line inside the slab. The ray then drifts further sideways from where it would have gone.
(c) No, not by that reasoning alone. P has the advantage of greater thickness and Q has the advantage of greater refractive index. The reasoning in (a) and (b) says only which way each factor acts, not by how much, and here the two factors favour different slabs. Working out the actual angles of refraction and drawing both paths to scale settles it: for these values P shifts the ray more than Q at every angle of incidence, because doubling the thickness outweighs the extra bending in Q.
