Given that $a$ and $b$ are roots of $x^2-3x+p=0$
$\Rightarrow\:a+b=3$ and $ab=p$........(i)
It is given that $c$ and $d$ are roots of $x^2-12x+q=0$
$\Rightarrow\:c+d=12$ and $cd=q$........(ii)
Also given that $a,b,c,d$ are in G.P.
Let $a,b,c,d$ be the first four terms of a G.P.
$\Rightarrow\:$ $a=a,\:\:b=ar\:\:c=ar^2\:\:d=ar^3$
Step 2
$\therefore\:a+b=3,\:\:\Rightarrow\:a+ar=3$
$\Rightarrow\:a(1+r)=3$.........(iii)
$c+d=12$ $\Rightarrow\:ar^2+ar^3=12$
$\Rightarrow\:ar^2(1+r)=12$.....(iv)
From (iii) and (iv) we get
$3.r^2=12$
$\Rightarrow\:r^2=4$ or $r=\pm 2$
Substituting the value of $r$ in (iii) we get $a=\large\frac{3}{1+2}$$=1$
$\therefore b=ar=2$
$c=ar^2=2^2=4$ and $d=ar^3=2^3=8$
$\Rightarrow\:ab=p=2$ and $cd=4\times 8=32$
$\Rightarrow\:q+p=32+2=34$ and $q-p=32-2=30$
$\Rightarrow\:q+p:q-p=34:30=17:15$
Hence proved.