Upgrade to remove ads
Terms in this set (7)
Logic or Boolean Value
can be only true (indicated by a non-zero number, typically 1) or false (indicated by the number 0) .
Assigning a logical value to a variable creates a logical variable that can hold only logical values. Logical variables can be used to test a logical state, namely whether something is either true or false, or to hold the outcome of a logical or a relational operation
checks whether two numerical values are the same (==) or different (~=).
a = b assigns a with b's value. In contrast, a == b returns true if a 's value is the same as b 's.
compares two numerical values and evaluates to a logical value of either true or false. Each operates on exactly two operands
compares two logical variables to reach a logical decision that results in a logical value (i.e. either true or false). A logical operator operates with logical values
short circuit evaluation
skips evaluating later operands if the result of the logical operator can already be determined.
The logical AND short circuit operator evaluates to false if the first operand evaluates to false, and skips evaluating the second operand.
The logical OR short-circuit operator evaluates to true if the first operand is true, and skips evaluating the second operand.
The relational operators and logical operators, except for ~, are binary operators, meaning they take two operands (from the left and right) and evaluate to true or false.
THIS SET IS OFTEN IN FOLDERS WITH...
Ch.2 - Variables, Assignments, and Expressions
1D Arrays (Ch.5,6,7)
Ch. 16 Branches
OTHER SETS BY THIS CREATOR
Ch.10 2D Array Basics
Ch.19 Strings and Characters
Ch. 1: The Molecular Basis of Hereditary, Variatio…
California DMV Permit Test 2018