Big Idea 3 · Topic 3.17 · Exercise 1
Count the Operations
25 minutes
Back to the Topic 3.17 lessonAll CSP topics
How this page works
The writing boxes below are yours. What you type stays in this browser, is saved here as you go, and is never sent to us or to your teacher. Hand the written work in the way your teacher asked for it.
The graded check at the bottom is the part that records to your teacher's gradebook.
Part B, from your handoutNot recorded
Your handout says these are the same items available here. Part A stays on paper.
Q1 · 3 points on the handout
Algorithms 1 and 2 could both be used to answer 'does this list contain a duplicate?' - Algorithm 1's style runs about n times, Algorithm 2's about n x n. Both are correct. Explain, using the CED's own idea, why you would prefer one over the other for a large list, and how you decided WITHOUT running either.
Q2 · 3 points on the handout
A teammate reruns Algorithm 2 on a computer twice as fast, sees it finish in half the time, and writes 'I made the algorithm more efficient.' Explain what is wrong, using the CED's definition of efficiency.
Q3 · 2 points on the handout
ENRICHMENT: Rank Algorithms 1-4 from most to least efficient for large n using only the words constant, linear, square, and cube - and state why ALL FOUR still count as running in a reasonable amount of time.
No graded check on this page yetNot recorded
About the line in your handout
Your handout says this exercise is available online and auto-graded. The exercise IS here, and it is the same work in the same order, but the auto-graded half is not written for this topic yet. Nothing on this page is scored or sent to your teacher.
Hand this in the way your teacher asked for it. Topic 1.1 has its graded check today, and the rest follow.