Question #223858

Write a function that take an array of number as input parameters and print the member that have remember of 4 when divided by 5


Expert's answer

public class Main {

    public static void modulo(int[] array) {
        for (int i : array) {
            if (i % 5 == 4) {
                System.out.print(i + " ");
            }
        }
    }
}

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

LATEST TUTORIALS
APPROVED BY CLIENTS