MCPcopy Create free account
hub / github.com/BeeBombshell/Python-DSA / Solution

Class Solution

Sort-all/bubble.py:2–9  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1
2class Solution:
3 def sortArray(self, N: List[int]) -> List[int]:
4 L, B = len(N), 1
5 while B:
6 B = 0
7 for i in range(L-1):
8 if N[i] > N[i+1]: N[i], N[i+1], B = N[i+1], N[i], 1
9 return N
10

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected