AAP-2.N For list operations:
a. Write expressions that use list indexing and list procedures.
b. Evaluate expressions that use list indexing and list procedures.
AAP-2.O For algorithms involving elements of a list:
a. Write iteration statements to traverse a list.
b. Determine the result of an algorithm that includes list traversals.
AAP-2.P For binary search algorithms:
a. Determine the number of iterations required to find a value in a data set.
b. Explain the requirements necessary to complete a binary search.
The objective for this lesson is to use List operations. Activity 1 will introduce List operations and evaluate expressions based on these procedures. Activity 2 will explore iterative List algorithms and explain the binary search algorithm in the context of finding an item in a List.
Activity 8.3.1 (55 minutes)
Facilitate students’ discussion on the iTunes operating capability added to the iPod in 2003 (PowerPoint slide 2).
Facilitate PowerPoint slides on modulo operators (PowerPoint slides 3, 5 (Python) or 4, 6 (Javascript)).
Present PowerPoint and video explaining the length function, List/Array slicing, and List/Array concatenation (PowerPoint slides 7 (Python) or 8 (Javascript), EarSketch Chapter 19 (Data Structure Operations)).
Facilitate PowerPoint slides on List/Array operations (PowerPoint slides 9, 11, 13 (Python) or 10, 12, 14 (Javascript)).
Assign students to to complete the Data Structure Operations Mini Task (PowerPoint slide 9).
Present each multiple-choice question to class and allow time for thought. Then, discuss as a group (PowerPoint slides 10-11).