\[3a - 3c + xa - xc =\]
\[= 3 \cdot (a - c) + x(a - c) =\]
\[= (a - c)(3 + x).\]
\[Проверка:\ \ \]
\[(a - c)(3 + x) =\]
\[= 3a - 3c + xa - xc.\]