Multiple choice

Which sorting algorithm moves the highest value to the end of the array with each pass?

  1. Bubble sort

  2. Selection sort

  3. Binary sort

  4. Boingo sort

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

Bubble sort works by repeatedly stepping through the list, comparing adjacent elements, and swapping them if they are in the wrong order. This process 'bubbles' the largest unsorted element to the end of the array in each pass.