1
Ohio State: Software I (CSE 2221)
Questions with 100% Correct Answers
What command is necessary after you are done using a
SimpleReader/SimpleWriter?
this_____ Correct Answer: this.close();
variable Correct Answer: the name of a "location" that "stores" a value of a
particular type
type Correct Answer: the name of the set of all possible values that a variable
might have
program variable Correct Answer: has a particular value at any one time during
program execution, and that value (generally) may change at other times
mathematical variable Correct Answer: an arbitrary but fixed value
program type Correct Answer: has a corresponding mathematical type that
models it
declare Correct Answer: providing a name for a location to store its value, and
indicate its program type
initialize Correct Answer: assigning a variable its value
literal Correct Answer: a data value appearing in a program
:
vPretest - Stuvia US
, 2
constant Correct Answer: a variable whose value is initialized and never
changed
operator Correct Answer: a symbol (or combination of a couple symbols) that is
used with variables and values to simplify how you write certain program
expressions
expression Correct Answer: a "syntactically well-formed and meaningful
fragment" (roughly analogous to a word in natural language)
statement Correct Answer: a "smallest complete unit of execution" (roughly
analogous to a sentence in natural language).
assignment statement Correct Answer: copies the value of the expression on the
right side of the assignment operator to the variable on the left side
block Correct Answer: any sequence of zero or more statements enclosed in {...}
conditional statement Correct Answer: if, if-else, if-else-if, switch...
loop statement Correct Answer: while, for, do-while
random sampling Correct Answer: class of computational methods to estimate
results; "throwing darts"
static method Correct Answer: a block of code with a name, using which it can
be called (invoked) to perform its computation, then "takes over" execution
when it is called, until it returns to the calling program at the point it was called
path of execution Correct Answer: going through a method, ending in a return
statement with an expression of the return type of the method
:
vPretest - Stuvia US
Ohio State: Software I (CSE 2221)
Questions with 100% Correct Answers
What command is necessary after you are done using a
SimpleReader/SimpleWriter?
this_____ Correct Answer: this.close();
variable Correct Answer: the name of a "location" that "stores" a value of a
particular type
type Correct Answer: the name of the set of all possible values that a variable
might have
program variable Correct Answer: has a particular value at any one time during
program execution, and that value (generally) may change at other times
mathematical variable Correct Answer: an arbitrary but fixed value
program type Correct Answer: has a corresponding mathematical type that
models it
declare Correct Answer: providing a name for a location to store its value, and
indicate its program type
initialize Correct Answer: assigning a variable its value
literal Correct Answer: a data value appearing in a program
:
vPretest - Stuvia US
, 2
constant Correct Answer: a variable whose value is initialized and never
changed
operator Correct Answer: a symbol (or combination of a couple symbols) that is
used with variables and values to simplify how you write certain program
expressions
expression Correct Answer: a "syntactically well-formed and meaningful
fragment" (roughly analogous to a word in natural language)
statement Correct Answer: a "smallest complete unit of execution" (roughly
analogous to a sentence in natural language).
assignment statement Correct Answer: copies the value of the expression on the
right side of the assignment operator to the variable on the left side
block Correct Answer: any sequence of zero or more statements enclosed in {...}
conditional statement Correct Answer: if, if-else, if-else-if, switch...
loop statement Correct Answer: while, for, do-while
random sampling Correct Answer: class of computational methods to estimate
results; "throwing darts"
static method Correct Answer: a block of code with a name, using which it can
be called (invoked) to perform its computation, then "takes over" execution
when it is called, until it returns to the calling program at the point it was called
path of execution Correct Answer: going through a method, ending in a return
statement with an expression of the return type of the method
:
vPretest - Stuvia US