\(x+y+z=0\Leftrightarrow\left(x+y+z\right)^2\)
\(\Leftrightarrow x^2+y^2+z^2=-2\left(xy+yz+zx\right)\)
\(P=\dfrac{x^2+y^2+z^2}{2\left(x^2+y^2+z^2\right)-2\left(xy+yz+zx\right)}=\dfrac{x^2+y^2+z^2}{2\left(x^2+y^2+z^2\right)+x^2+y^2+z^2}=\dfrac{1}{3}\)