ch08Sections1-5

# ch08Sections1-5 - 8.10 Exercises Problems and Projects...

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

8.10 Exercises, Problems, and Projects 8.10.1 Multiple Choice Exercises: 1. int [] a; and int a[]; 2. 0 3. 29 4. 0 5. a[6] 6. An array can be sized dynamically, but cannot be resized without instantiating it again. 7. a.length 8. true 9. false 10. false 11. true 12. true 8.10.2 Reading and Understanding Code 13. 48.3 14. 0 15. 3 16. 12 48 65 17. a[0] = 12 a[1] = 48 a[2] = 65 18 s = 125 19. 14 20. 99.6 21. 12 23 65 48 22. It counts how many elements in the argument array have the value 5 23. It returns the index of the first element in the argument array with value 10. If no element in the argument array has value 10, it returns –1. 24. If the argument array has at least one element that is negative, it returns false , otherwise it returns true . 25. It returns an array of Strings identical to the argument array except that the Strings are all in lowercase. 26. It returns an array of booleans as follows: if an element in the argument array contains the character @, then the corresponding element in the returned array is

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

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### Page1 / 3

ch08Sections1-5 - 8.10 Exercises Problems and Projects...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online