Longest Substring Without Repeating Characters - Leetcode #3 (Medium) - Javascript