Two lines in 3D are either: (1) Intersecting (coplanar, share a point), (2) Parallel (coplanar, no shared point, same direction), (3) Skew (not coplanar, neither parallel nor intersecting).
Coplanarity test: Lines r=a1+tb1 and r=a2+sb2 are coplanar iff (a2-a1).(b1 x b2) = 0, i.e., the scalar triple product [a2-a1, b1, b2] = 0. In component form: the determinant |x2-x1 y2-y1 z2-z1; a1 b1 c1; a2 b2 c2| = 0.
If coplanar: the lines either intersect (b1 x b2 != 0) or are parallel (b1 x b2 = 0). To find the intersection point, solve the parametric equations simultaneously.
Shortest distance between skew lines: SD = |(a2-a1).(b1 x b2)|/|b1 x b2|. This is the length of the common perpendicular. The direction of the common perpendicular is b1 x b2.
Finding the actual points of closest approach: solve for t and s from the system (a1+tb1 - a2-sb2) perpendicular to both b1 and b2. This gives two linear equations in t and s.
The equation of the plane containing two intersecting (or parallel) lines can be found by taking the normal as b1 x b2 (for intersecting) or b x (a2-a1) (for parallel), and using any point on either line.
JEE strategy: First check coplanarity using the determinant. If zero, find intersection by solving parametric equations. If non-zero, compute shortest distance using the formula.