Step 1: Identify direction vectors and points.
For line 1:
\begin{itemize}
\item Point \( P(1,1,0) \)
\item Direction vector \( \mathbf{d_1} = (2,-1,1) \)
\end{itemize}
For line 2:
\begin{itemize}
\item Point \( Q(2,1,-1) \)
\item Direction vector \( \mathbf{d_2} = (3,-5,2) \)
\end{itemize}
Step 2: Compute vector \( \mathbf{PQ} \).
\[
\mathbf{PQ} = (2-1, 1-1, -1-0) = (1,0,-1)
\]
Step 3: Compute shortest distance formula.
The formula for shortest distance between two skew lines is:
\[
d = \frac{|(\mathbf{PQ} \cdot (\mathbf{d_1} \times \mathbf{d_2}))|}{|\mathbf{d_1} \times \mathbf{d_2}|}
\]
First, compute \( \mathbf{d_1} \times \mathbf{d_2} \):
\[
\mathbf{d_1} \times \mathbf{d_2} =
\begin{vmatrix}
\hat{i} & \hat{j} & \hat{k}
2 & -1 & 1
3 & -5 & 2
\end{vmatrix}
\]
\[
= \hat{i}((-1)(2) - (1)(-5)) - \hat{j}((2)(2) - (1)(3)) + \hat{k}((2)(-5) - (-1)(3))
\]
\[
= \hat{i}( -2 + 5 ) - \hat{j}(4 - 3) + \hat{k}(-10 + 3)
\]
\[
= \hat{i}(3) - \hat{j}(1) + \hat{k}(-7)
\]
\[
= (3, -1, -7)
\]
Step 4: Compute \( \mathbf{PQ} \cdot (\mathbf{d_1} \times \mathbf{d_2}) \).
\[
(1,0,-1) \cdot (3,-1,-7) = (1)(3) + (0)(-1) + (-1)(-7)
\]
\[
= 3 + 0 + 7 = 10
\]
Step 5: Compute magnitude of \( \mathbf{d_1} \times \mathbf{d_2} \).
\[
|\mathbf{d_1} \times \mathbf{d_2}| = \sqrt{3^2 + (-1)^2 + (-7)^2}
\]
\[
= \sqrt{9 + 1 + 49} = \sqrt{59}
\]
Step 6: Compute shortest distance.
\[
d = \frac{|10|}{\sqrt{59}}
\]
\[
d = \frac{10}{\sqrt{59}}
\]
\[
d = \frac{10\sqrt{59}}{59}
\]
Final Answer:
\[
d = \frac{10\sqrt{59}}{59}
\]