- Esecutori
-
Impara
Centro di apprendimento Python Esempi eseguibili, NumPy, pandas e altro Centro di apprendimento C e C++ Puntatori, memoria, STL e C++ moderno Centro di apprendimento C#Fondamenti, OOP, LINQ, async ed esercizi .NET Algoritmi Python Ricerca, ordinamento, ricorsione e visualizzazioni O(n) Algoritmi C e C++ Confronta le implementazioni in C e C++
- Sfide
Visualizers
Sorting Algorithm Visualizer
See how classic sorting algorithms work, one comparison and swap at a time.
- Runs in your browser
- Instant results
- Free, no sign-up
Loading the tool…
How to use the Sorting Algorithm Visualizer
- Choose an algorithm, the number of elements and the starting data.
- Press Play, or Step to go one operation at a time.
- Compare comparisons, swaps and the complexity table between algorithms.
Frequently asked questions
Which sorting algorithm is fastest?
On random data, quick, merge and heap sort (O(n log n)) beat the O(n²) sorts. Insertion sort wins on nearly sorted data.
What does stable mean?
A stable sort keeps equal values in their original order, which matters when sorting records by one field.
Why try different starting data?
Some algorithms behave very differently on sorted, reversed or repetitive input; quick sort's worst case shows on sorted data.
Esercitati in Python con le sfide di codice
Risolvi problemi pratici direttamente in questo editor: esegui i test di esempio, invia la soluzione e ricevi una revisione AI del codice.