JS-Methods Flashcards

1
Q

Why do we use console.log

A

easier to debug

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

what is a method?

A

function which is a property of an object

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

how do you remove last element from array

A

.pop

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

how do you round a number down

A

math.round

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

how do you generate a random number

A

math.random

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

how do you delete an element

A

.splice

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

how to append an element from an array

A

.push

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

how to break up string into array

A

.split

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

do string methods change original string?

A

no they do not, can console.log to see if they did

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

Is return value useful in every situation

A

no

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

3 letter acronym for research?

A

MDN

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