M3S2 Part 3 Flashcards

1
Q

the symbols that tell the compiler to perform specific

mathematical or logical manipulations.

A

Operators

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Types of Operators

A
  • Assignment Operator
  • Arithmetic Operators
  • Compound Operators
  • Relational Operators
  • Logical Operators
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

a single equal sign (=) which
means that the value on the right side of the assignment expression
after the equal sign is assigned to the variable on the left.

A

assignment operator

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

specifies the
order of operations in expressions
that contain more than one operator.

A

Operator precedence

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

compound operators:

A

+= , -= , *= , /=, %=

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

y+= x; is equivalent to?

A

y = y+x

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

++ adds 1 to its operand

A

increment operator

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

– subtracts 1 from its operand.

A

decrement operator

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Both the increment and decrement operators can either

A

precede

(prefix) or follow (postfix) the operand.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q
operators that allow
the comparison of two or more
numerical values, yielding a result
based on whatever the
comparison is true(1) or false(0).
A

relational operators

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q
These operators are used to
combine two or more
conditions or to complement
the evaluation of the original
condition in consideration.
A

logical operators

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

The
result of the operation of a
logical operator is a

A

boolean

value either true or false

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

If both the operators are non-zero, then condition becomes true.

A

&& Logical AND operator

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

If any of the two operands is non-zero, then the condition becomes true

A

Logical OR Operator. ||

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Use to reverses the logical state of its operand. If a condition is true, then this operator will make false

A

! Logical NOT Operator

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

works on bits and perform bit-by-bit operation.

A

Bitwise operator

17
Q

Bitwise inclusive OR

18
Q

Bitwise exclusive OR

19
Q

Unary complement (bit inversion)

20
Q

Shift bits left

A

&laquo_space;SHL

21
Q

Shift bits right

22
Q

copies a bit to the

result if it exists in both operands.

A

Binary AND Operator &

23
Q

copies a bit if it

exists in either operand.

A

Binary OR Operator |

24
Q

copies the bit if it is

set in one operand but not both.

A

^ Binary XOR Operator

25
is | unary and has the effect of 'flipping' bits.
Binary Ones Complement Operator ~
26
he left operands value is moved left by the number of bits specified by the right operand.
he left operands value is moved left by the number of bits specified by the right operand.
27
The left operands value is moved right by the number of bits specified by the right operand.
Binary Right Shift Operator >
28
are used to construct conditional expressions.
The conditional operators | ? and :
29
Conditional operators are | also called as
ternary | operators.