If Else
You will use what you learn about these scripts to solve the puzzles in problem 2.
Conditional statements: Blocks like if else
and repeat until
allow your programs to perform different actions or computations depending on a condition that you specify.
Predicates: Blocks such as or
that report only
or
are called predicates. In snap, predicates are hexagonal in shape, not oval like other reporters. The values
and
themselves are predicates called Booleans.
if else
the way I think we were supposed to, but we also found a way to do them with repeat until
and even a way without using any conditionals at all.
if else
. Do you think there is a way?
if else
with your method that uses no conditionals. What are the advantages/disadvantages of each method?repeat until
.if else
?