A light L switches on (L = 1) when it is dark (D = 1) and either movement is detected (M = 1) or the manual switch is on (S = 1). Write the logic expression for L.
- "Movement or the manual switch" gives M OR S.
- This must be true together with darkness, so join it to D with AND.
- Brackets keep the OR part together: L = D AND (M OR S).
- Check: D = 0, M = 1, S = 1 gives 0 AND 1 = 0, so the light stays off in daylight, as required.
Answer: L = D AND (M OR S)