Given an object containing user information and an object containing preferences, merge the two objects together.
// input:
const user = { firstName: 'Bruce', lastName: 'Wayne', 'phoneNumber': '123-456-7890' }
const preferences = { favoriteMovie: 'The Dark Knight', favoriteFood: 'Pizza' };
// output:
{ firstName: 'Bruce', lastName: 'Wayne', 'phoneNumber': '123-456-7890', favoriteMovie: 'The Dark Knight', favoriteFood: 'Pizza' }
(Ctrl + ')
Loading...
/* output */
Next(Ctrl + y)