COM
Ch06_Logic8e_Solutions

Ch06_Logic8e_Solutions - Programming Logic and Design 8e...

Info icon This preview shows pages 1–4. Sign up to view the full content.

Programming Logic and Design, 8e Solutions 6- Programming Logic and Design, 8th Edition Chapter 6 REVIEW QUESTIONS 1. A subscript is a(n) _____. a. element in an array b. alternate name for an array c. number that represents the highest value stored within an array d. number that indicates the position of an array element 2. Each element in an array must have the same _____ as the others. 3. Suppose you have declared a numeric array named values that has 13 elements. Which of the following must be true? 4. The subscripts of any array are always _____. 1
Image of page 1

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

Programming Logic and Design, 8e Solutions 6- 5. Suppose that you have declared a numeric array named numbers , and two of its elements are numbers[1] and numbers[4] . You know that _____. a. the two elements hold the same value b. the array holds exactly four elements c. there are exactly two elements between those two elements d. the two elements are at the same memory location 6. Suppose that you have declared a numeric array named numbers , and two of its elements are numbers[1] and numbers[4] . You know that _____. 7. Suppose that you want to write a program that inputs customer data and displays a summary of the number of customers who owe more than $1000 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 _____. 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. 2
Image of page 2
Programming Logic and Design, 8e Solutions 6-
Image of page 3

Info icon This preview has intentionally blurred sections. Sign up to view the full version.

Image of page 4
This is the end of the preview. Sign up to access the rest of the document.
  • Fall '15
  • NUM, sentinel value

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern