MCPcopy Index your code
hub / github.com/BeeBombshell/Python-DSA / merge

Method merge

Sort-all/merge.py:9–15  ·  view source on GitHub ↗
(LH, RH)

Source from the content-addressed store, hash-verified

7 return merge(LH,RH)
8
9 def merge(LH, RH):
10 LLH, LRH = len(LH), len(RH)
11 S, i, j = [], 0, 0
12 while i < LLH and j < LRH:
13 if LH[i] <= RH[j]: i, _ = i + 1, S.append(LH[i])
14 else: j, _ = j + 1, S.append(RH[j])
15 return S + (RH[j:] if i == LLH else LH[i:])
16
17 return mergesort(N)
18

Callers

nothing calls this directly

Calls 1

appendMethod · 0.80

Tested by

no test coverage detected