✦MYSIMULATOR / 2D LAB← All simulations
Simulation 14 / 20 · Algorithms

Sorting Algorithm Race: Watch Bubble Sort Find Order

Follow every comparison and swap as bubble sort transforms a disordered dataset into ascending order.

Computer science · Sorting algorithmsInteractive experimentLive model
Live simulation viewportCanvas · 2D model

What you're exploring

Bubble sort repeatedly compares adjacent values and swaps them when they are out of order. Each pass moves the largest remaining value toward the end of the array. The algorithm is easy to visualise, although its average time complexity is O(n²).

Made with 🤖 ChatGPT