Đáp án:
$\displaystyle \begin{array}{{>{\displaystyle}l}} a.S=\{-1;1;2\}\\ b.\ m=-\frac{1}{4} \end{array}$
Giải thích các bước giải:
$\displaystyle \begin{array}{{>{\displaystyle}l}} \left( x^{2} -x-m\right) .( x-1) =0\\ a.\ Với\ m=2,\ PT\ trở\ thành\\ \left( x^{2} -x-2\right)( x-1) =0\\ \Leftrightarrow ( x-2)( x+1)( x-1) =0\\ \Leftrightarrow \ x=2\ or\ x=-1\ or\ x=1\\ VậyS=\{-1;1;2\}\\ b.\ \left( x^{2} -x-m\right) .( x-1) =0\ ( 1)\\ \Leftrightarrow \ x=1\ or\ x^{2} -x-m=0\\ Ta\ thấy\ ( 1) \ luôn\ có\ 1\ nghiệm\ x=1\ nên\ \\ để\ ( 1) \ có\ 2\ nghiệm\ phân\ biệt\ \\ \Leftrightarrow x^{2} -x-m=0\ có\ 1\ nghiệm\ x\neq 1\\ \Leftrightarrow \Delta =1+4m=0\ và\ 1-1-m\ \neq 0\\ \Leftrightarrow m=-\frac{1}{4} ,\ m\ \neq 0\\ Vậy\ m=-\frac{1}{4}\\ \\ \end{array}$