2. Fix the leaking shared state
EasyDebugging & productionDebugging
addTag should return a new list containing the given tags plus the new tag, without changing its input. Each call is independent, but results leak between calls.
Example 1
Input: addTag('a'); addTag('b')
Output: ['b'] for the second callConstraints
Fix the bug; keep the function signature