Notes Flashcards

1
Q

____ is where the type is bound to the variable. Types are checked at compile time.

A

Static/Strong typing

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

____ is where the type is bound to the value. Types are checked at run time.

A

Dynamic/Loosely typing

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

Curly braces are used for

A

Grouping code blocks

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

What does it mean that Javascript objects are mutable?

A

They are addressed by their reference, not by their value.

ie. x = 16, x points to 16 but isn’t equal to it.

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

True or False? Making changes to the reference (ie. X) will change the object?

A

True

var person = {firstName ="Paul}
var x = person.age;
x.age = 10;
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

True or false? Variables are mutable

A

False

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

True or False? Methods are properties in Javascript

A

True

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

How does this way of accessing a javascript object work?

x = “age”;person[x]

A

Accessing age of person x, but assigns it to variable x.

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

___ is used to request data from a specified resource.

A

GET

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

____ is used to send data to a server to create/update a resource.

A

POST

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

Why bother with building an object, when you can use an array

A

Objects can have methods

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q
True or false?
console.log(person.firstName);
is equivalent to
x = "firstName";
console.log(person["x"));
A

True

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

A method inside of an object is just another _____

A

property

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

What is the “this” keyword?

A

Refers to the properties within the object itself.

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