
CSP-Algorithm
Quiz
•
Science, Computers
•
University
•
Practice Problem
•
Medium
闕河正 闕河正
Used 3+ times
FREE Resource
Enhance your content in a minute
17 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Algorithm 1 calculates the correct sum, but algorithm 2 does not.
Algorithm 2 calculates the correct sum, but algorithm 1 does not.
Both algorithms calculate the correct sum.
Neither algorithm calculates the correct sum.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
1/n
n^2
n
n^3
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
A high school provides email addresses to freshman students. The email system typically assigns an email address in the format "firstname.lastname@coolschool.edu". However, if a student has the same name as a previous student, the system assigns them a different format.
In order to figure out whether an email address is already assigned, the system does a binary search through its list of existing email addresses.
Which of these statements is true?
The list of email addresses must be sorted for binary search to work.
In the worst case that the email address is not in the list, binary search will need to look at every item in the list.
The code for the binary search algorithm must be written in binary to achieve optimum efficiency.
The list of email addresses don't need to be sorted for binary search to work, but that would improve the efficiency of the algorithm.
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Ryland is creating an article about commonly used compression algorithms for an online educational site.
He's debating whether to express each algorithm in natural language, flow charts, pseudocode, or C++, a general-purpose programming language.
Which of these is a good argument for expressing the algorithm in pseudocode?
Pseudocode can express more detail than natural language, flow charts, and C++.
Pseudocode doesn't depend on the syntax and subtleties of a particular programming language, so his readers will be able to understand it as long as they know at least one language.
Pseudocode can be understood by anyone, even those without any programming experience.
Pseudocode can run on any computer, so all his readers will be able to run the algorithm themselves.
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
1900 false
1984 true
2000 false
2002 false
1900 true
1984 true
2000 false
2002 false
1900 false
1984 true
2000 true
2002 false
1900 true
1984 true
2000 true
2002 false
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
解決同一個問題有a,b,c,d四個程式能做到,其時間複雜度分別為
A.6n^2
B.6n
C.1/n
D.2^n
請依據效能由好到壞排序(假設n很大)
C > B > A > D
B>D>A>C
D>B>C>A
A>B>C>D
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Yes, that test case is sufficient proof that the procedure works as intended for all possible lists of numbers.
No, since the expected return value is not [1, 2, 3, 4] for that test case.
No, but the programmer can conclude that it always works when generating lists that are 4 numbers long.
No, they've only verified that it works for that test case. Additional analysis and reasoning is necessary.
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?
Similar Resources on Wayground
15 questions
Quiz sobre Núcleo Celular
Quiz
•
8th Grade - University
13 questions
Podsumowanie: binarny, komputer, sieć
Quiz
•
7th Grade - University
12 questions
RDBG LO4 LS1-6
Quiz
•
University
20 questions
DI (EM24) - Diseño de Perfiles (T5)
Quiz
•
University - Professi...
12 questions
Javascript
Quiz
•
University
12 questions
IELTS Reading - History of the Steam Engine
Quiz
•
University - Professi...
16 questions
Quiz on List and Tuples
Quiz
•
University
13 questions
Astronomy Quiziz
Quiz
•
University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
