CS174: OOP - Drills - Counting Array Zeroes
Developed by Professor Tralie and Professor Mongan.
Exercise Goals
The goals of this exercise are:- To do proper array indexing
- To use loops in concert with arrays
- To use logic inside of a loop
- To declare accumulator variables outside of loops that are used in loops, but whose state persists beyond the loop
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