MIS 525 Week 6 Quiz 2 | Devry University
- Devry University / MIS 525
- 16 Dec 2021
- Price: $10
- Management Assignment Help / Management Information Systems
MIS 525 Week 6 Quiz 2 | Devry University
Week 6 Review Questions - ONLINE VERSION
Question 1
A subscript is a(n) _____.
· element in an array
· alternate name for an array
· number that represents the highest value stored within an array
· number that indicates the position of a particular item in an array
Question 2
Each variable in an array must have the same _____ as the others.
· data type
· subscript
· value
· memory location
Question 3
Each data item in an array is called a(n) _____.
· data type
· subscript
· component
· element
Question 4
The subscripts of any array are always _____.
· integers
· fractions
· characters
· strings of characters
Question 5
"Suppose you have an array named number, and two of its elements are number[1] and number[4]. You know that _____."
· the two elements hold the same value
· the array holds exactly four elements
· there are exactly two elements between those two elements
· the two elements are at the same memory location
Question 6
"Suppose you want to write a program that inputs customer data and displays a summary of the number of customers who owe more than $1,000 each, in each of 12 sales regions. Customer data variables include name, zipCode, balanceDue, and regionNumber. At some point during record processing, you would add 1 to an array element whose subscript would be represented by _____."
· name
· zipCode
· balanceDue
· regionNumber
Question 7
The most useful type of subscript for manipulating arrays is a _____.
· numeric constant
· variable
· character
· filename
Question 8
"A program contains a seven-element array that holds the names of the days of the week. At the start of the program, you display the day names using a subscript named dayNum. You display the same array values again at the end of the program, where you _____ as a subscript to the array."
· must use dayNum
· "can use dayNum, but can also use another variable"
· must not use dayNum
· must use a numeric constant instead of a variable
Question 9
"Suppose you have declared an array as follows: num values[4] = 0, 0, 0, 0. Which of the following is an allowed operation?"
· values[2] = 17
· input values[0]
· values[3] = values[0] + 10
· all of the above
Question 10
Filling an array with values during a program s execution is known as _____ the array.
· executing
· colonizing
· populating
· declaring
Question 11
Using an array can make a program _____.
· easier to understand
· illegal in some modern languages
· harder to maintain
· all of the above
Question 12
A _____ is a variable that you set to indicate whether some event has occurred.
· subscript
· banner
· counter
· flag
Question 13
What do you call two arrays in which each element in one array is associated with the element in the same relative position in the other array?
· cohesive arrays
· parallel arrays
· hidden arrays
· perpendicular arrays
Question 14
"In most modern programming languages, the highest subscript you should use with a 10-element array is _____."
· 8
· 9
· 10
· 11
Question 15
Parallel arrays _____.
· frequently have an indirect relationship
· never have an indirect relationship
· must be the same data type
· must not be the same data type
Question 16
Each element in a five-element array can hold _____ value(s).
· one
· five
· at least five
· an unlimited number of
Question 17
"After the annual dog show in which the Barkley Dog Training Academy awards points to each participant, the academy assigns a status to each dog based on the following criteria: The academy needs a program that compares a dog s points earned with the grading scale, so that each dog can receive a certificate acknowledging the appropriate level of achievement. Of the following, which set of values would be most useful for the contents of an array used in the program?"
Points Earned Level of Achievement
0–5 Good
6–7 Excellent
8–9 Superior
10 Unbelievable
· "0, 6, 9, 10"
· "5, 7, 8, 10"
· "5, 7, 9, 10"
· any of these
Question 18
"When you use a subscript value that is negative or higher than the number of elements in an array, _____."
· execution of the program stops and an error message is issued
· a value in a memory location that is outside the area occupied by the array will be accessed
· "a value in a memory location that is outside the area occupied by the array will be accessed, but only if the value is the correct data type"
· the resulting action depends on the programming language used
Question 19
"In every array, a subscript is out of bounds when it is _____."
· negative
· 0
· 1
· 999
Question 20
You can access every element of an array using a _____.
· while loop
· for loop
· both of the above
· none of the above