bubble sort with flag