Jabit Soft interview question

Given a nested object, flatten it into a single-level object.