Question 7
Consider the following JavaScript code:
const products = [ { id: 101, name: "laptop", price: 800 }, { id: 102, name: "mouse", price: 25 }, { id: 103, name: "keyboard", price: 60 }, { id: 104, name: "monitor", price: 300 }];
const priorities = { "102": 1, "104": 2, "101": 3, "103": 4 };
products .filter((product) => product.price > 50) .map((product) => { return { ...product, priority: priorities[product.id] } }) .sort((a, b) => a.priority - b.priority) .forEach((product) => { console.log(product.name); });What will be the output of the code?