Updated Chapter 3 Bubble sort