Learn algorithms, systems, and AI by tracing how they run.

Change the input, scrub the trace, and see code, visuals, and logs stay in sync.

bubble.pydefbubble(arr):n=len(arr)foriinrange(n-1):forjinrange(n-i-1):ifarr[j]>arr[j+1]:swap(arr,j,j+1)12345631420123Try your own:3142watch the state move

More to explore

Foundations · Algorithms · AI · CS · Capstones

View learning path177 interactive lessons