making decisions
TRANSCRIPT
MAKING DECISIONS
Should I go outside to play?
MAKING DECISIONS
Should I go outside to play?
If it’s raining
I will stay home
MAKING DECISIONS
Should I go outside to play?
If it’s raining
I will go play
MAKING DECISIONS
Should I go outside to play?
If I have too much homework
I will stay home
Otherwise
I will go to play
MAKING DECISIONS
Should I go outside to play?
If my friends go
I will also go
HOW DO WE MAKE DECISIONS?
If some condition is True,!
then I will perform some action
If the card Leena picked is a black card,
First, Koena will jump up twice
After that, Sahith will clap three times
After that, Rohin will write ‘gigglygoo’ on a piece of paper
Otherwise,
First, Ishaan will say, ‘I will put on the cloak !and enter the Forbidden Forest’
After that, Suneet will draw a circle on a whiteboard
First, Leena will pick a card
if card.color == ‘black’:
Koena.jump(2)
Sahith.clap(3)
Rohin.write(‘gigglygoo’)
else:
Ishaan.say(‘I will put on the cloak \!and enter the Forbidden Forest’)
Suneet.draw(‘circle’)
card = Leena.pickCard()
If the card Leena picked is a black face card,
After that, Koena will draw a flower on a whiteboard
Ishaan will imitate a tree for 5 seconds
After that, Rohin will do three jumping jacks
Otherwise, if the card Leena picked is a red face card,
First, Sahith will say, ‘Hi! My name is Fluffy’
First, Suneet will clap 4 times
First, Leena will pick a card
Otherwise,
if card.color == ‘black’ AND card.isFaceCard():
Koena.draw(‘flower’)
Ishaan.imitate(‘tree’, 5)
Rohin.doJumpingJacks(3)
elif card.color == ‘red’ AND card.isFaceCard():
Sahith.say(‘Hi! My name is Fluffy’)
Suneet.clap(4)
card = Leena.pickCard()
else:
if card.isNumberCard() AND card.number == 6:
Ishaan.jump(3)
Suneet.imitate(‘bird’, 4)
Suneet.doJumpingJacks(4)
elif card.isNumberCard() AND card.number == 7:
Koena.say(‘I am not a zombie’)
Rohin.imitate(‘vampire’, 4)
card = Leena.pickCard()
else:
Sahith.clap(2)
elif card.isNumberCard() AND card.number == 8:
Koena.clap(3)
CONDITIONS
True!or!
False
It is raining outside
Koena is in class today
Suneet is not in class today
It is not raining outside
5 is greater than 4
The word ‘cake’ has 5 letters in
it
The word ‘cake’ does NOT have 4 letters in it
4 is NOT greater than 5
5 is less than 4
5 is NOT less than 4
5 is equal to 5
5 is NOT equal to 5
4+5 is equal to 10
Cake is in the fridge
Cake is on the table
Cake is on the table OR in the
fridge
Cake is on the table AND in the
fridge
Cake is on the table AND in the
fridge
Cake is on the table OR in the
fridge
cake is on the table OR in the fridge
Cake is on the table OR cake is not on
the table
Cake is on the table AND cake is not on
the table
5==5
4==5
‘hello’==‘hello’
‘hello’==‘Hello’
4<5
4>5
4<=5
5<=5
4+5<10
5!=5