E-Learning Platform
0 of 139 builtAlways freeSign in
3.02 · Lab

Types & Operators

Math, gluing, and comparing — three jobs, and + picks between the first two based on what's sitting either side of it. Read the thermostat carefully.

Exercise

Read a thermostat

Checks itself — try as often as you like

In the script pane:

  • Declare let temperature set to 68.
  • Declare let doubled set to temperature * 2.
  • Declare let unit set to the string "F".
  • Declare let reading set to temperature + " " + unit (so it reads "68 F").
  • Declare let isWarm set to whether temperature is greater than 65.