Skip to content

Commit

Permalink
autofix
Browse files Browse the repository at this point in the history
  • Loading branch information
Felienne committed Oct 6, 2023
1 parent 0dad64f commit d4ec310
Showing 1 changed file with 40 additions and 45 deletions.
85 changes: 40 additions & 45 deletions content/adventures/ca.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -624,15 +624,14 @@ adventures:
```
start_code: '# place your code here'
13:
story_text: |4
### Exercise 1
Let's make the practice program a bit harder. The player now has to answers two questions correctly. Fill out the blanks to complete the program.
story_text: |
### Exercise 1
Let's make the practice program a bit harder. The player now has to answers two questions correctly. Fill out the blanks to complete the program.
### Exercise 2 (extra)
Sometimes, calculations have multiple correct answers. For example, 10 can be divided by 5 and by 2. So the question 'What number divides 10?' can be answered by 2 and by 5.
Ask for a calculation that has multiple correct answers, ask the player to answer it, and determine if it is correct using `{or}`.
Empty the programming field and create your own solution.
### Exercise 2 Extra
Sometimes, calculations have multiple correct answers. For example, 10 can be divided by 5 and by 2. So the question 'What number divides 10?' can be answered by 2 and by 5.
Ask for a calculation that has multiple correct answers, ask the player to answer it, and determine if it is correct using `{or}`.
Empty the programming field and create your own solution.
example_code: |
```
answer1 = {ask} 'What is 10 times 7?'
Expand Down Expand Up @@ -1053,9 +1052,8 @@ adventures:
{if} throw {is} earthworm points = points + 5 {else} points = points + throw
{print} 'those are' points ' point'
```
example_code_2: |4
Did you manage to calculate the score for 8 dice? That required a lot of cutting and pasting, right? We are going to make that easier in level 7!
example_code_2: |
Did you manage to calculate the score for 8 dice? That required a lot of cutting and pasting, right? We are going to make that easier in level 7!
start_code: '{print} ''What will the die indicate this time?'''
7:
story_text: |
Expand Down Expand Up @@ -1303,18 +1301,16 @@ adventures:
story_text: |
In the previous levels you've created your first fortune telling machine, but Hedy couldn't really predict anything, only {echo}.
In this level you can use a variable and the `{at} {random}` command to really let Hedy choose an answer for you. Check out this code for instance:
example_code: |4
In this example the player can {ask} Hedy a yes-no question and Hedy will pick a random answer for you.
```
{print} I’m Hedy the fortune teller!
question {is} {ask} What do you want to know?
{print} This is what you want to know: question
answers {is} yes, no, maybe
{print} My crystal ball says...
{sleep} 2
{print} answers {at} {random}
```
example_code: |
```
{print} I’m Hedy the fortune teller!
question {is} {ask} What do you want to know?
{print} This is what you want to know: question
answers {is} yes, no, maybe
{print} My crystal ball says...
{sleep} 2
{print} answers {at} {random}
```
story_text_2: |
### Exercise
Now, Hedy can only answer yes, no or maybe. Can you give Hedy more answer options, like 'definitely' or 'ask again'.
Expand Down Expand Up @@ -2490,8 +2486,8 @@ adventures:
description: Create your own virtual restaurant
levels:
1:
story_text: |4
In level 1 you can make your own virtual restaurant and take your guests' orders.
story_text: |
In level 1 you can make your own virtual restaurant and take your guests' orders.
example_code: |
```
{print} Welcome to Hedy's restaurant 🍟
Expand Down Expand Up @@ -2599,22 +2595,21 @@ adventures:
6:
story_text: |
In this level you can use maths to calculate the total price of your customer's order, which can make your virtual restaurant more realistic.
example_code: |4
You can make a simple restaurant code, like this:
```
{print} 'Welcome to Hedys restaurant'
{print} 'Here is our menu:'
{print} 'Our main courses are pizza, lasagne, or spaghetti'
main = {ask} 'Which main course would you like?'
price = 0
{if} main {is} pizza price = 10
{if} main {is} lasagne price = 12
{if} main {is} spaghetti price = 8
{print} 'You have ordered ' main
{print} 'That will be ' price ' dollars, please'
{print} 'Thank you, enjoy your meal!'
```
example_code: |
You can make a simple restaurant code, like this:
```
{print} 'Welcome to Restaurant Chez Hedy'
{print} 'Here is our menu:'
{print} 'Our main courses are pizza, lasagne, or spaghetti'
main = {ask} 'Which main course would you like?'
price = 0
{if} main {is} pizza price = 10
{if} main {is} lasagne price = 12
{if} main {is} spaghetti price = 8
{print} 'You have ordered ' main
{print} 'That will be ' price ' dollars, please'
{print} 'Thank you, enjoy your meal!'
```
start_code: '# place your code here'
7:
story_text: |
Expand Down Expand Up @@ -2820,11 +2815,11 @@ adventures:
```
start_code: '# place your code here'
3:
story_text: |4
story_text: |
You can use the `{at} {random}` command to let the computer pick rock, paper or scissors!
In this level we can enter lists and choose things from them.
You first make a list with `{is}`. Then you can let the computer choose something from the list with `{at} {random}`.
For example, you can let the computer pick from rock, paper and scissors.
### Exercise
Finish the code by using the `{at} {random}` command.
example_code: |
```
choices {is} rock, paper, scissors
Expand Down

0 comments on commit d4ec310

Please sign in to comment.