Virtusa interview question

Explain bubble sort algorithm with example.