CS174: OOP - Drills - Counting Array Zeroes

Developed by Professor Tralie and Professor Mongan.


Exercise Goals

The goals of this exercise are:
  1. To do proper array indexing
  2. To use loops in concert with arrays
  3. To use logic inside of a loop
  4. To declare accumulator variables outside of loops that are used in loops, but whose state persists beyond the loop
Modify the countZeroes method in ArrayZeroes.java file to count the number of zeroes in an array (this is based on exercise 13 on page 266 of the Horstmann book Java for Everyone).
Welcome to our online modules system! Be sure to log in with your Urinus ID before you proceed. For example, Professor Tralie's ID is ctralie. If you are not an Ursinus student, that's fine! Just make something up, and you can still run everything