
$\mathrm{f}_4(\mathrm{x})$ is many-one onto, continuous and non-derivable
$f_3(x)$ is many-one, into, continuous and derivable
$\mathrm{f}_2(\mathrm{x})$ is one-one, into, differentiable
Hence $R \rightarrow 2$
So,
$p \rightarrow 1, q \rightarrow 3, R \rightarrow 2, S \rightarrow 4$