Instructor solution
You may exit out of this review and return later without penalty.
Variables and Expressions Review Assignment
1.Describe what the following pseudocode does: \(\text{a} \leftarrow \text{expression}\)
2.What does the pseudocode INPUT() do?
3.Explain what the pseudocode NOT condition does.
4.Explain what the following pseudocode is doing: \(a \leftarrow b + c\)
5.What does the pseudocode DISPLAY(expression) mean?
6.Write pseudocode that creates two variables, aVar and bVar, with values of 15 and 30, respectively.
7.Write pseudocode that sets the value of a variable temperature to user input, then displays that value.
8.Write pseudocode that creates two variables, aVar and bVar, and sets them both to random values between 1 and 10 (inclusive).
9.Write pseudocode that assigns the value true to a variable isHotToday, then assigns the opposite value to a variable isColdToday. Do not use \(\text{isColdToday} \leftarrow \text{false}\)!
10.What does the following pseudocode do?
> \(aVar \leftarrow 15\)
> \(aVar \leftarrow aVar * 2 + 3\)
> \(\text{DISPLAY}(aVar)\)
11.What is wrong with the following pseudocode?
> \(numA \leftarrow 15\)
> \(\text{DISPLAY}(numA + numB)\)
> \(numB \leftarrow 5\)
You may exit out of this review and return later without penalty.