Giải thích các bước giải:
a, Đường thẳng $d$ qua $A, B$ có $VTCP : \overrightarrow{u} = \overrightarrow{AB} = (-3; -3)$
$\to d$ có $VTPT : \overrightarrow{u} = (3; -3)$
$d$ đi qua $A(1; 4)$ $\to$ $ptđt d: 3(x - 1) - 3(y - 4) = 0$
$\to x - y + 3 = 0$
b, $d(M; d) = \dfrac{\left | 1.1 - 1.7 + 3 \right |}{\sqrt{1^{2} + 1^{2}}} = \dfrac{3}{\sqrt{2}}$