javascript-operators-and-expressions Flashcards

1
Q

What data type is returned by an arithmetic operation?

A

number

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

What is string concatenation?

A

string concatenation is inlcuding the value of a variable in-line with a string , a tring with a number or combining two or more strings.

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

What purpose(s) does the + plus operator serve in JavaScript?

A

In JavaScript, the + operator serves multiple purposes. It can be used as an arithmetic operator to perform addition, as well as a string concatenation operator to combine or join strings.

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

What data type is returned by comparing two values (<, >, ===, etc)?

A

a boolean

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

What does the += “plus-equals” operator do?

A

+= is the same as var sum = sum + {value} - adds value on right hand side of the operator to the varable and then stores it back to the variable.

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