Challenge 3: Transaction or Not? — Possible Solution ==================================================================== (a) Updating a single user's last_login timestamp — NO transaction needed. This is a single updateOne() against one document in one collection. A single-document write is already atomic in MongoDB by default; wrapping it in a transaction would add overhead for zero extra safety. (b) Moving a task between two different users' embedded tasks arrays — YES, this needs a transaction, and it's the trickiest case precisely because each individual write IS atomic on its own. Removing the task from User A's document and adding it to User B's document are each, separately, perfectly safe single-document updates. The problem is the PAIR of them together: without a transaction, a crash between the two writes can leave the task removed from User A but never added to User B (the task vanishes entirely), or added to User B while still present on User A (the task duplicates). Each write being individually atomic does not make the overall two-step operation atomic — that's exactly what a transaction adds. (c) Transferring loyalty points between two separate customer_accounts documents — YES, this needs a transaction, for the same reason as the classic bank-transfer example in this chapter: decrementing one account's points and incrementing another's are two independent single-document writes. Without a transaction, a failure between them can destroy points (deducted from one account, never credited to the other) or create them out of nothing (credited without ever being deducted) — both are Atomicity/Consistency failures a transaction prevents by making both writes succeed or fail as one unit.