{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

CS202 Array Exercise spr2008

CS202 Array Exercise spr2008 - CS201 Array Exercise 1 Don't...

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

View Full Document Right Arrow Icon
CS201 Array Exercise 1. Don't write the following programs. But, if you DID write them, would you need an array? Circle a) Read in 10 integers and print only the largest. Yes No b) Read in 10 integers and print them in reverse order. Yes No c) Read in 10 integers and sort them in order from smallest to largest. Yes No d) Read in 10 integers and print only the sum. Yes No e) Read in 10 integers and print only the average. Yes No f) Read in 10 integers and print only the numbers which are above average.Yes No 2. Give the statements that declare tests and quizzes to be arrays that can store 20 integer values. Give the subscript range. 3. Give the statement that declares apple to be a string array that can store 100 strings. Give the subscript range. 4. Give the statement(s) that will: a) assign a value of 332 to the 3 rd element of tests. b) put "delicious" in the 5 th element of apple. c) put the value located in the 3 rd element of tests into the 8 th element of quizzes.
Image of page 1

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

View Full Document Right Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

{[ 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