For this problem, add an AbsoluteValue action with one integer parameter and a integer return value. Once you have completed the action, call the action with the argument -78 (e.g., result = AbsoluteValue(-78)). Then, output the result. When run, the program should output the following.
-6 -2 15 17.0 true 78
Coding:
Hotkey Shortcuts
Move BlocksUP or DOWN or TAB
Run Program ALT + SHIFT + R
Stop Program ALT + SHIFT + S
Hide Tray ALT + SHIFT + X
Zoom In ALT + +
Zoom Out ALT + -
Open Help ALT + SHIFT + H
Navigate to Tray ALT + 1
Navigate to Blocks ALT + 2
Enter Navigation Mode SHIFT + ENTER
Switch to Next Tab CTRL + Tab
Switch to Previous TabCTRL + Shift + Tab
Blocks
Hint
Great job!
Try again
Using the other actions as a guide, build the AbsoluteValue action, action AbsoluteValue(integer a) returns integer. Use an if block to check if the parameter is a negative number if it is return -a.