ax^2 -x(a-1)+ 5=0
p + q =\frac{a-1}{a}
p q =\frac{5}{a}
the eqn is
\frac{p}{q} +\frac{q}{p} =\frac{p^2 + q^2}{pq}
\frac{p^2 + q^2}{pq} =\frac{(p+q)^2-2pq}{pq} =\frac{4}{5}
=\frac{(\frac{a-1}{a})^2-2(\frac{5}{a})}{\frac{5}{a}} =\frac{4}{5}
cross multplyin and solvn we have eqn as
a^2 -16a +1=0
a_{1} +a_{2} =16
a_{1} a_{2} =1
\frac{a_{1}^2 +a_{2}^2}{a_{1}a_{2}} =\frac{(a_{1}+a_{2})^2- 2a_1a_2}{a_1a_2}
\frac{(a_{1}+a_{2})^2- 2a_1a_2}{a_1a_2} =\frac{256 -2}{1}=\boxed{254}
@ che bhaiyya