How to learn algorithm properly?

Now I started learning javascript in algorithm topic but I stuck most of these challenge and I just code following the code explanation and take a note for each code from that.
I found that there are many method I didn’t learn before e.g. split(), Math.max() and I think sometimes I don’t have the correct logic to solve the problem in the challenge. So I want to know the way I can improve myself for better understanding the algorithm or have a correct logic.

You may often need to do research as part of solving the challenge. You’ve gotten far enough in JavaScript to be able to do some of your own problem solving instead of simple read-and-repeat lessons. If you look at the solutions consistently, then the only thing you are going to learn is how to read code, not how to use it to solve problems. Remember to do research, look at your notes, review previous lessons as needed. As you are working on the problem, it’s perfectly normal for part of the process to be asking questions here.

Thank you for your suggestion. I’ve got the point now. I think I have to do research along with the problem in the challenge and read more documentation to solve the problem.