Chapter 2 - Programming By Example Flashcards

Ch 2 from Eric Roberts

You may prefer our related Brainscape-certified flashcards:
1
Q

What are statements?

A

The steps that the method performs, which are listed between the curly braces

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

Reductionism

A

Philosophical principle that the whole of an object can be be understood by understanding the parts that make it up

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

Holistic

A

Philosophical principle that the whole is often more than the sum of its parts.

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

Variable

A

A placeholder for some piece of data whose value is unknown when the program is written.

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

What do programmers often use to indicate values assigned to variables

A

boxes

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

Inheritance

A

The property of taking on the behavior of the superclass

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

overriding a method

A

redefining an existing method so that it does something different from that in it’s superclass

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

An expression in java is composed of?

A

terms of operators.

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

Syntax for declaring a variable

A

type identifier = expression

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

Instance variables

A

variables declared in a class but outside of any method

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

class variables

A

defined at the class level rather than the method

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

static keyword

A

indicates the declaration introduces a class variable rather than an instance variable

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

What do you need to use to assign a new value to a variable

A

assignment statement

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

Instance Variables

A

Hold the state

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

Methods that return types of Boolean

A

Predicate

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

Process of calling a predicate method is analogous to

A

Asking a yes/no question and getting an answer