diff --git a/docs/lessons/headbands/activity.md b/docs/lessons/headbands/activity.md index a8c467bf..f0aaff87 100644 --- a/docs/lessons/headbands/activity.md +++ b/docs/lessons/headbands/activity.md @@ -5,7 +5,7 @@ Your beginning code should look like this: ```blocks -let coll = ([]) +let coll = new Array coll.push("puppy") coll.push("clock") coll.push("night") @@ -27,7 +27,7 @@ game.startCountdown(30000) Let's add more words for the player to act out! But first, we need to increase the time in one round to give the player more time get through all the words. Let's change the `game->start countdown` statement. ```blocks -let coll = ([]) +let coll: string[] = [] coll.push("puppy") coll.push("clock") coll.push("night") @@ -52,7 +52,8 @@ game.startCountdown(60000) Now let's add 5 more words to our list of charade words. Right above the the line `word:=coll->at(index)` add 5 lines that say `coll->add("")`. In this example, we will add the words **bicycle, telephone, sun, car, and ant** but you can add whatever words you like. ```blocks -let coll.push("puppy") +let coll: string[] = [] +coll.push("puppy") coll.push("clock") coll.push("night") coll.push("cat") diff --git a/docs/lessons/headbands/quiz-answers.md b/docs/lessons/headbands/quiz-answers.md index d7c3c7b7..697cbec7 100644 --- a/docs/lessons/headbands/quiz-answers.md +++ b/docs/lessons/headbands/quiz-answers.md @@ -19,7 +19,7 @@ A 'collection' is a group of variables of the same type stored together. A 'coll ## 2. Consider the following lines of code. ```blocks -let coll = ([]) +let coll: string[] = [] coll.push("puppy") coll.push("clock") ``` @@ -35,7 +35,7 @@ basic.showString(coll[0], 150) ## 3. Consider the following lines of code. ```blocks -let coll = ([]) +let coll: string[] = [] coll.push("puppy") coll.push("clock") coll.push("cat") @@ -52,7 +52,7 @@ basic.showString(coll[2], 150) ## 4. Consider the following line of code. ```blocks -let coll = ([]) +let coll: string[] = [] ``` Write the five (5) lines of code that will add the following five words to `data->coll`: puppy, clock, night, cat, cow. @@ -60,7 +60,8 @@ Write the five (5) lines of code that will add the following five words to `data
```blocks -let coll.push("puppy") +let coll: string[] = [] +coll.push("puppy") coll.push("clock") coll.push("night") coll.push("cat")