The syntax for forEach is incorrect. The function should be passed as a parameter with two parentheses following it. The correct syntax is: fruits.forEach((x) => console.log(`I love ${x}`));
const fruits = [ 'apple', 'orange', 'banana' ]; 

fruits.forEach(x =>  console.log(`I love ${x}`) );
Scopri perché questo codice non funziona