Search
⌘K

Leetcode 2755. Deep Merge of Two Objects

Recursively merge two nested (JSON-like) objects into a single object, combining keys and merging sub-objects while resolving conflicts. When a key exists in both, merge their values if both are objects; otherwise use the second object's value (respect array/primitive handling and avoid unintended mutation or recursion issues).


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Comments

Your account is free and you can post anonymously if you choose.