IBM Interview Question

Explain the bubble sort works?