If the given array is {6,2, 5, 1, 9 }, the 3rd number from the left while doing bubble sort in the 2nd iteration is
Answers
Answered by
25
6 2 5 1 9
Iteration 1:
6 2 5 1 9
2 6 5 1 9
2 5 6 1 9
2 5 1 6 9
2 5 1 6 [9]
Iteration 2:
2 5 1 6 9
2 5 1 6 9
2 1 5 6 9
2 1 5 [6] [9]
Therefore, the 3rd number from left while doing 2nd iteration is 5
Answered by
0
Answer:
5
Step-by-step explanation:
Similar questions
Math,
5 months ago
Math,
5 months ago
Computer Science,
5 months ago
Math,
11 months ago
Chemistry,
11 months ago