Question: Write a static method countEvens ( ) that has five integer paramet number ( i . e . evenly divisible by 2 ) . Ex:

Write a static method countEvens() that has five integer paramet number (i.e. evenly divisible by 2).
Ex: If the five parameters are:
1,22,11,40,37
then the returned count will be:
2
Hint: Use the modulo operator % to determine if each number is eve
Your program must define the method:
public static int countevens(int num1, int num2,
LabProgram.java
(3)46
 Write a static method countEvens() that has five integer paramet number

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!