Write a for loop that prints in ascending order all the positive multiples of 5 that are less than 175, separated by spaces.

Write a for loop that prints in ascending order all the positive multiples of 5 that are less than 175, separated by spaces.

LANGUAGE: JAVA

CHALLENGE:
Write a for loop that prints in ascending order all the positive multiples of 5 that are less than 175, separated by spaces.

SOLUTION:

{for (int n = 5; n < 175; n +=5)
System.out.print(n + " ");
}

Add comment