If
Statementsabs of -10
and abs of 10
are both 10" with a number line picture?speech balloon
and thought balloon
, which completely deals with the sound-v-print problem and probably mostly deals with the question Jane called attention to. Explain this in a teacher note with something like: say
tells us information by making the sprite display that information on the stage, but it does not report a value that another procedure can use. report
reports a value and, depending on what is done with the value, may or may not show that value to us.traffic signal
block receives something other than "red," "yellow," or "green" as input.Debugging code
Only two of them work properly.
Experiment with them and look at the code to see what they do. Explain what causes the buggy one to fail.
Type your answer there and click the check box (or hit return).
Analyzing code
Load these blocks that use if
and if else
and try each one.
With your pair programmer figure out how each one does what it does.
Two of these scripts use the block. In the Operators palette, this block shows up as .
To select abs
(or any of several mathematical functions), click the drop-down menu.
The absolute value of a number is that number's distance from zero.
As the number line shows, -3 and 3 are the same distance from 0, so abs(-3)
and abs(3)
are both 3. abs(-2.5)
is 2.5.
In mathematical notation, we write abs(-3)
as |-3|.
mystery3
do?