Variables

Programmers often think of variable names as names for memory locations, but there is much more to a variable than just a name.
👁 320
statistics
calculate
Questions #: 10
Time:
Pass Score: 80.0%
Style
Mode

A program variable is an abstraction of a computer memory cell or collection of cells.

POINTS (1)

Correct Answer

Explanation

A variable can be characterized as a sextuple of attributes

(name, address, value, type, lifetime, and scope)

POINTS (1)

Correct Answer

Explanation

A program variable is not associated with a machine address

POINTS (1)

Correct Answer

Explanation

In many languages, it is possible for the same variable to be associated with different addresses at different times in the program

POINTS (1)

Correct Answer

Explanation

A memory address in the program can be accessed by

POINTS (1)

Correct Answer

Explanation

Two variables are aliases

Variable named sum and totalwhere both are aliases.  If the following operations are made to total, what is the value of sum?

sum = 1
total = 2
total = total + 3
POINTS (1)

Correct Answer

Explanation

A value of a variable is stored in exactly a single physical memory cell

POINTS (1)

Correct Answer

Explanation

In Java, a declared variable rose is same as variable ROSE

POINTS (1)

Correct Answer

Explanation

In C++, pointer variables and references

Two pointer variables are aliases when they point to the same memory location. The same is true for reference variables.

POINTS (1)

Correct Answer

Explanation

In C and C++, union types can be used to create aliases in a program

POINTS (1)

Correct Answer

Explanation

Views:
Trials:
Avg score:
0
sin cos tan
sin-1 cos-1 tan-1 π e
xy x3 x2 ex 10x
y√x 3√x √x ln log
( ) 1/x % n!
7 8 9 + MS
4 5 6 M+
1 2 3 × M-
0 . EXP ÷ MR
± RND C = MC

Document Actions