Safely access deeply nested object properties using a path string or array.
Asked in frontend interviews at Google, Meta, Amazon and 4 more