the loop is not a bad start, but you should not return the function itself
the average is calculated by summing all numbers together and dividing by the number of numbers

you have scores, the function parameter, which is an array of numbers
you need to sum together all the numbers in this array, and then divide by the number of items in this array.

if you need other variables, feel free to declare them, if you need other things use them, this is totally free in implementation

good start with the for-loop, but you shouldn’t call the function inside the for-loop, instead you should sum all the elements of the array and divide the sum by the number of elements of the array. Good Luck!

A large part of programming is solving problems you have never solved before.
When you encounter a problem, then you should research on google or forums.
Professional developers run into issues all of the time, and they use google all of the time.
That is the skill you are learning and practicing here.

For this problem, you have created the loop but you haven’t added all of the numbers in the array to get the sum.

So what you will need to google is "how to add up a list of numbers for loop javascript"
There are tons of beginner friendly articles showing you how to do that.

Once you get the sum, then you can get the average and the lessons shows you how to do that.
Then you will have completed step 1