If A + B = 1 and (x — 2) is a factor of x2 + Ax + B, find the value of B