[JS] Loops and part of Arrays

Solved all tasks from Loops and part of Arrays tasks