Skip to content

Commit

Permalink
Nieuwe parsons tm level 12
Browse files Browse the repository at this point in the history
  • Loading branch information
MarleenGilsing committed Aug 31, 2023
1 parent fb68393 commit e940491
Show file tree
Hide file tree
Showing 2 changed files with 221 additions and 0 deletions.
111 changes: 111 additions & 0 deletions content/parsons/en.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -176,3 +176,114 @@ levels:
{print} counter
{sleep} 1
{print} 'Ready or not here I come!'
9:
1:
story: |
This game will give you three maths assignments. Each time the question is different. Can you figure out the order?
code: |
numbers = 1, 2, 3, 4, 5, 6, 7, 8, 9, 10
{repeat} 3 {times}
number = numbers {at} {random}
correct_answer = 5 * number
answer = {ask} 'What is 5 times' number '?'
{if} answer = correct_answer
{print} 'Good job!'
{else}
{print} 'No! The correct answer is ' correct_answer
2:
story: |
This code asks the costumers in a restaurant if they would like to order dessert. If they do, it asks them what kind of dessert. If they order tiramisu they are told that the tiramisu is sold out.
Can you get the code to work?
code: |
order = {ask} 'Would you like to order dessert?'
{if} order = yes
dessert = {ask} 'What kind of dessert would you like?'
{if} dessert = tiramisu
{print} 'Sorry, we are out of tiramisu.'
{else}
{print} 'One ' dessert ' coming right up!'
{else}
{print} 'You dont want a dessert. No problem!'
10:
1:
story: |
Help this family out by creating a schedule of who is cooking and what they should be making this week. The remove commands make sure nobody has to cook twice and they have a differnet dinner every day.
**Mind!** the variable order should be first days, then people, and lastly dinner_options. This goes for the lines with the remove commands too.
code: |
days = Monday, Tuesday, Wednesday, Thursday, Friday
people = mom, dad, Martin, Abby, Jesse
dinner_options = pizza, tacos, pancakes, a salad, lasagne
{for} day {in} days
chosen_person = people {at} {random}
chosen_dinner = dinner_options {at} {random}
{print} 'On ' day ' ' chosen_person ' is making ' chosen_dinner
{remove} chosen_person {from} people
{remove} chosen_dinner {from} dinner_options
2:
story: |
This make-over robot will decide your new hairstyle for you. If you do not agree with the first choice, you can try again.
**Mind** The variable people is defined in the first line. The variable hairstyles in the second.
code: |
people = Betty, Amanda, Marc
hairstyles = a bald head, a mohawk, a ponytail, spikes
{for} person {in} people
{print} person ' will get ' hairstyles {at} {random}
happy = {ask} person ', are you happy with this choice?'
{if} happy {is} yes
{print} 'Great'
{else}
{print} 'Lets try again... Then 'person ' will get ' hairstyles {at} {random}
11:
1:
story: |
Create the count down clock for New Year's eve! The program should show the numbers from 10 to 1 for a second and then wish you a happy new year.
code: |
{for} number {in} {range} 10 {to} 1
{print} number
{sleep}
{clear}
{print} 'Happy New Year!'
2:
story: |
Create a program that tells us the final results of the science fair. Firstly define the variable contestants, then the variable place.
**Hint** Line 5 should be the sleep command, and you should end with saying congratulations.
code: |
{print} 'And now we will reveal the results of the science fair'
contestants = Vivienne, Paul, Trixy, Bianca, Katya
place = 5
{for} contestant {in} contestants
{sleep} 2
{print} 'On number ' place ' has ended... ' contestant
place = place - 1
{print} 'Congratulations!'
12:
1:
story: |
Sing the song 'What shall we do with the drunken sailor'. In case you don't know it, the song goed like this:
What will we do with the drunken sailor
What will we do with the drunken sailor
What will we do with the drunken sailor
Early in the morning
Way hey and up she rises
Way hey and up she rises
Way hey and up she rises
Early in the morning
code: |
verses = 'What will we do with the drunken sailor', 'Way hey and up she rises'
{for} verse {in} verses
{for} count {in} {range} 1 {to} 3
{print} verse
{print} 'Early in the morning'
2:
story: |
Play a game of Twister with us! First define the variable people, then limbs, then colors.
code: |
people = 'Jess', 'Nick', 'Winston'
limbs = 'left hand', 'left foot', 'right hand', 'right foot'
colors = 'red', 'blue', 'green', 'yellow'
{for} person {in} people
{print} person ', put your ' limbs {at} {random} ' on ' colors {at} {random}
110 changes: 110 additions & 0 deletions content/parsons/nl.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -173,3 +173,113 @@ levels:
{print} teller
{sleep} 1
{print} 'Wie niet weg is, is gezien! Ik kom!'
9:
1:
story: |
Dit spelletje geeft je 3 verschillende rekensommen. Kun jij het spelletje aan de praat krijgen?
code: |
nummers = 1, 2, 3, 4, 5, 6, 7, 8, 9, 10
{repeat} 3 {times}
nummer = nummers {at} {random}
correct_antwoord = 5 * nummer
antwoord = {ask} 'Wat is 5 keer' nummer '?'
{if} antwoord = correct_antwoord
{print} 'Super!'
{else}
{print} 'Nee! Het antwoord is ' correct_antwoord
2:
story: |
Deze code vraagt aan klanten in een restaurant of ze een toetje willen bestellen. Als ze dat willen wordt er gevraagd welk toetje. Willen ze tiramisu, dan wordt er gezegd dat dat helaas op is.
Kun jij de volgorde van de regels bepalen?
code: |
bestelling = {ask} 'Wilt u een toetje?'
{if} bestelling = ja
toetje = {ask} 'Wat voor toetje wilt u?'
{if} toetje = tiramisu
{print} 'Sorry, we hebben helaas geen tiramisu meer.'
{else}
{print} 'Een ' toetje ', komt eraan!'
{else}
{print} 'Geen toetje? Geen probleem!'
10:
1:
story: |
Help deze familie een schema te maken voor wie wanneer wat moet koken. Zorg met de {remove} commando's dat er nooit twee dagen hetzelfde wordt gegeten en dat iedereen maar één keer hoeft te koken.
**Let op!** De volgorde van de variabelen is eerst dagen, daarna mensen en als laatste diner_opties. Deze volgorde geldt ook bij de {remove} commando's.
code: |
dagen = maandag, dinsdag, woensdag, donderdag, vrijdag
mensen = mama, papa, Martin, Abby, Jesse
diner_opties = pizza, tacos, pannenkoeken, een salade, lasagne
{for} dag {in} dagen
gekozen_persoon = people {at} {random}
gekozen_diner = diner_opties {at} {random}
{print} 'Op ' dag ' kookt ' gekozen_persoon ' ' gekozen_diner
{remove} gekozen_persoon {from} mensen
{remove} gekozen_diner {from} diner_opties
2:
story: |
This make-over robot will decide your new hairstyle for you. If you do not agree with the first choice, you can try again.
**Mind** The variable people is defined in the first line. The variable hairstyles in the second.
code: |
mensen = Betty, Amanda, Marc
haarstijl = een kaal hoofd, een hanekam, een paardenstaart, stekeltjes
{for} mesn {in} mensen
{print} mens ' krijgt nu ' haarstijl {at} {random}
tevreden = {ask} mens ', ben je blij met deze keuze?'
{if} tevreden {is} ja
{print} 'Fantastisch'
{else}
{print} 'We proberen het opniew... ' mens ' krijgt ' haarstijl {at} {random}
11:
1:
story: |
Maak een aftelklok voor oudjaarsavond! Het programma moet de getallen van 10 tot 1 één seconde tonen en je dan een gelukkig nieuwjaar wensen!
code: |
{for} getal {in} {range} 10 {to} 1
{print} getal
{sleep}
{clear}
{print} 'Gelukkig nieuwjaar!'
2:
story: |
Maak een programma dat ons de uitslag van de wetenschapswedstrijd kan vertellen. Definieer eerst de variabele deelnemers en daarna de variabele plek.
**Tip** Regel 5 is het {sleep} commando en je eindigt met een felicitatie naar de deelnemers.
code: |
{print} 'En dan nu.. de resultaten van de wetenschapswedstrijd'
deelnemers = Vivienne, Paul, Trixy, Bianca, Katya
plek = 5
{for} deelnemer {in} deelnemers
{sleep} 2
{print} 'Op plek ' plek ' is geëindigd... ' deelnemer
plek = plek - 1
{print} 'Gefeliciteerd!'
12:
1:
story: |
Zing het lied 'De dronken zeeman'. Dit is de songtekst:
Wat zullen we doen met de dronken zeeman?
Wat zullen we doen met de dronken zeeman?
Wat zullen we doen met de dronken zeeman?
's Morgens in de vroegte
Hela hup, daar gaat ie
Hela hup, daar gaat ie
Hela hup, daar gaat ie
's Morgens in de vroegte
code: |
coupletten = 'Wat zullen we doen met de dronken zeeman', 'Hela hup, daar gaat ie'
{for} couplet {in} coupletten
{for} teller {in} {range} 1 {to} 3
{print} couplet
{print} 's Morgens in de vroegte'
2:
story: |
Speel een potje Twister! Stel de variabele mensen eerst in, daarna ledematen en tot slot kleuren.
code: |
mensen = 'Jess', 'Nick', 'Winston'
ledematen = 'linkerhand', 'linkervoet', 'rechterhand', 'rechtervoet'
kleuren = 'rood', 'blauw', 'groen', 'geel'
{for} mens {in} mensen
{print} mens ', zet je ' ledematen {at} {random} ' op ' kleuren {at} {random}

0 comments on commit e940491

Please sign in to comment.