Sorting Numpy Array Initialization Javascript Map