
Sorting in Java
Authored by Ryan Goulet
Computers
10th - 12th Grade
Used 70+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
9 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Under what condition will a selection sort execute faster?
If the data is already sorted in ascending order
If the data is already sorted in descending order
It will always take the same time
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which sort should be the fastest most of the time?
selection sort
insertion sort
mergesort
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What would the code return from mystery([90, -30, 50], 50)
-1
50
1
2
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following correctly shows the iterations of an ascending (from left to right) insertion sort on an array with the following elements: {7,3,8,5,4}?
{3,7,8,5,4},{3,7,8,5,4},{3,5,7,8,4},{3,4,5,7,8}
{3,4,8,5,7},{3,4,5,7,8}
{3,7,8,5,4}{3,5,7,8,4},{3,4,5,7,8}
{4,7,3,8,5},{4,3,7,8,5},{3,4,5,7,8}
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following correctly shows the iterations of an ascending (from left to right) selection sort on an array with the following elements: {10, 6, 3, 2, 8}?
{6,10,3,2,8}, {3,6,10,2,8}, {2,3,6,10,8}, {2,3,6,8,10}
{6,10,3,2,8}, {3,6,10,2,8}, {2,3,6,8,10}
{2,6,3,10,8}, {2,3,6,10,8}, {2,3,6,8,10}
{2,6,3,10,8}, {2,3,6,10,8}, {2,3,6,10,8}, {2,3,6,8,10}
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Answer correctly
["$ bills", "120 dogs", "Tennis", "alien", "ma", "manners"]
[ "120 dogs", "$ bills",, "Tennis", "alien", "ma", "manners"]
["$ bills", "120 dogs", "alien", "ma", "manners", "Tennis"]
[ "120 dogs", "$ bills", "alien", "ma", "manners", "Tennis"]
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
b, p, D, E, y, S
D, E, b, p, y, S
E, b, p, E, y, S
b, p, y, E, D, S
E, E, S, b, p, y
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?