This is a numerical-answer question. The correct answer is shown below.
[Solution by Dr. Abubacker] A point of the first line is $(t,t,1)$ with direction $(1,1,0)$. $(t-a)+(t-a)=0\Rightarrow t=a$, so $Q=(a,a,1)$. A point of the second line is $(s,-s,-1)$ with direction $(1,-1,0)$. $(s-a)-(-s-a)=2s=0$, so $R=(0,0,-1)$. $\overrightarrow{PQ}=(0,0,1-a)$ and $\overrightarrow{PR}=(-a,-a,-1-a)$. $\overrightarrow{PQ}\cdot\overrightarrow{PR}=(1-a)(-1-a)=a^2-1=0$, so $a^2=1$ and $12a^2=12$. Answer: 12.