A hydrocarbon ‘P’ (\( \mathrm{C_4H_8} \)) on reaction with HCl gives an optically active compound ‘Q’ (\( \mathrm{C_4H_9Cl} \)) which on reaction with one mole of ammonia gives compound ‘R’ (\( \mathrm{C_4H_{11}N} \)). ‘R’ on diazotization followed by hydrolysis gives ‘S’. Identify P, Q, R and S.