[algorithms] merge sort implemented