Map() question For Loop Problem

I am now currently working on Functional Programming. Even though I haven’t used the for loop but still tells me that I have used for loop. Here is my code

let rating ={
  return {'title': x.Title, 'rating': x.imdbRating};

And here is the question

Can anyone tell me what is wrong here ?
Thank You.

It’s working for me when I copy/paste your solution and REPLACE the original version. Did you just comment out the original for loop, perhaps? When I did that, the test failed.

Yes, I did that @vipatron.

So it passes now that you’ve deleted the commented code?

And after Deleting the for loop I get the result. Thanks a lot @vipatron.

1 Like

Go ahead and mark my original comment as the solution then. Have a good day!