I’d recommend looking into Math.min() and Math.max(). That will help get you started. You’re trying to get the highest number and the lowest number in the array.
You are getting the numbers from the array correctly, use console.log() to double check yourself. You also have a return in your for loops, which will just return a += firstN in the first loop and stop the function right there. If you remove those you are getting the correct number in your function, but you will still need to return it someplace else.
You where very close with your original code. Forget the Math.min and Math.max for now, we can use that later to clean up your original code a little after you get this working if you want.
Like i said your original code was very close. Your if statement is correct in choosing the highest and lowest numbers, but get those returns out of your for loops. And it looks like you are using a to collect your answer, just return that someplace else and it should work.