Section 7.9

Coding Task

Learning Goals


AAP-2.H.2: The exam reference sheet provides

IF(condition)

{

<block of statements>

}

in which the code in block of statements is executed if the Boolean expression condition evaluates to true; no action is taken if condition evaluates to false. 

AAP-2.H.3: The exam reference sheet provides

IF(condition)

{

 <first block of statements>

}

ELSE

{

 <second block of statements>

}

in which the code in first block of statements is executed if the Boolean expression condition evaluates to true; otherwise, the code in second block of statements is executed. 


Objectives and Description

The objective of this lesson is to provide students with exposure to the agnostic coding language used in the AP CSP exam through a coding task. Additionally, this task is meant to prepare students for the second sprint of their ARC Challenge.

Activities

Activity 7.9.1 (55 minutes)


For example, the final song structure for a song that has 3 choruses should be the following:


The answer key for this prompt is provided for the teachers.