BACK

Earth Daily Question

Write a function that merges the following inputs into a single list.

??
		
const combineList = function(listOriginal,listAdd,listDelete) {
	let merged = listOriginal.concat(listAdd); 
	let answer = [...new Set(merged)];
	answer = answer.filter( function(x) {
		return !listDelete.includes(x);
	} );
	return answer;
};