Question: 20
(Choose 1 answer)
(See picture)
A. 3
B. 4
C. 5
D. 6
E. None of the other choices is correct
procedure bubble sort (a1, a2, ,an integers)fori-1 ton-1 for j = 1 ton-i if aj > aj+1 then swap(aj,aj+1)
In the bubble sort algorithm
if the input is the list
{4,2,3,1}
how many swaps are used?